You've successfully subscribed to The Poor Coder | Hackerrank Solutions
Great! Next, complete checkout for full access to The Poor Coder | Hackerrank Solutions
Welcome back! You've successfully signed in.
Success! Your account is fully activated, you now have access to all content.


Beeze Aal

Hackerrank Covariant Return Types Solution

Java allows for Covariant Return Types, which means you can vary your return type as long you are returning a subclass of your specified return type. Method Overriding allows a subclass to override the behavior of an existing superclass method and specify a return type that is some subclass of
Beeze Aal

Hackerrank Java Singleton Pattern Solution

"The singleton pattern is a design pattern that restricts the instantiation of a class to one object. This is useful when exactly one object is needed to coordinate actions across the system."  - Wikipedia: Singleton PatternComplete the Singleton class in your editor which contains the following components: A private Singleton
Beeze Aal

Hackerrank Java Factory Pattern Solution

According to Wikipedia, a factory is simply an object that returns another object from some other method call, which is assumed to be "new". In this problem, you are given an interface Food. There are two classes Pizza and Cake which implement the Food interface, and they both contain a
Beeze Aal

Hackerrank Java Lambda Expressions Solution

.MathJax_SVG_LineBox {display: table!important} .MathJax_SVG_LineBox span {display: table-cell!important; width: 10000em!important; min-width: 0; max-width: none; padding: 0; border: 0; margin: 0} This Java 8 challenge tests your knowledge of Lambda expressions! Write the following methods that return a lambda expression performing a specified action: PerformOperation
Beeze Aal

Hackerrank Java Annotations Solution

Java annotation can be used to define the metadata of a Java class or class element. We can use Java annotation at the compile time to instruct the compiler about the build process. Annotation is also used at runtime to get insight into the properties of class elements. Java annotation
Beeze Aal

Hackerrank Can You Access? Solution

You are given a class Solution and an inner class Inner.Private. The main method of class Solution takes an integer  as input. The powerof2 in class Inner.Private checks whether a number is a power of . You have to call the method powerof2 of the class Inner.Private from