Govt Exams
String s1 = new String('Amazon');
String s2 = new String('Amazon');
System.out.println(s1 == s2);
== compares memory references. Both s1 and s2 are different objects, so it prints false. Use .equals() for value comparison.
Insertion Sort has O(n) time complexity for nearly sorted data, making it the most efficient choice.
Linked List is ideal for queue implementation as it provides O(1) insertion and deletion at both ends.
Linear Programming is an optimization technique, not a programming paradigm. The others are paradigms used in software development.
'Each' is singular, so it should be 'is' not 'are'. Correct sentence: 'Each of the students is required to submit their project by Friday.'
The passage explains that climate change affects different regions differently - some get more rain (floods) while others get less (droughts).
Verbose means using many words. Laconic means brief or using few words - the opposite meaning.
Ephemeral means short-lived or temporary. Transient has the same meaning. Other options mean lasting or permanent.
121(11²), 144(12²), 169(13²), 196(14²) are perfect squares. 220 is not a perfect square.
Each letter is coded by its position in the alphabet. O=15, R=18, A=1, N=14, G=7, E=5