Quiz

Question: What will be the output?
if(1 + 1 + 1 + 1 + 1 == 5){
System.out.print("TRUE");
}
else{
System.out.print("FLASE");
}
Options:
A.TRUE
B.FALSE
C.Compiler Error
D.None of these
Answer: Option A

Submit Answer & Explaination

Earn Reward Points by submitting Detailed Explaination for this Question

More Questions on This Topic :

Question 1. Which of the following is the correct expression that evaluates to true if the number x is between 1 and 100 or the number is negative?
  1.    1 < x < 100 || x < 0
  2.    ((x < 100) && (x > 1)) || (x < 0)
  3.    ((x < 100) && (x > 1)) && (x < 0)
  4.    (1 > x > 100) || (x < 0)
Answer: Option B
Question 2. Public class Test{
      public static void main(String args[]){
            System.out.print(""=="");
            System.out.print(" ");
            System.out.print("A"=="A");
            System.out.print(" ");
            System.out.print("a==A");
      }
}
  1.    "==" A"=="A a==A
  2.    true true false
  3.    true true a==A
  4.    Compilation Fails
  5.    None of the above
Answer: Option C
Question 3. What will be the output?
public class Test{
public static void main(String args[]){
int a = 42;
double b = 42.25;
System.out.print((a%10)+" "+(b%10));
}
}
  1.    42 42.5
  2.    2 2.5
  3.    4.2 4.225
  4.    2 4.225
  5.    Compilation Error
Answer: Option B
Question 4. Select from among the following character escape code which is not available in Java.
  1.    \t
  2.    \r
  3.    \a
  4.    \\
  5.    \v
Answer: Option C
Question 5. What is the output of the following program ?
class Numbers{
public static void main(String args[]){
int a=20, b=10;
if((a < b) && (b++ < 25)){
System.out.println("This is any language logic");
}
System.out.println(b);
}
}
  1.    12
  2.    11
  3.    10
  4.    Compilation Error
Answer: Option C
Question 6. Int ++a = 100 ;
System.out.println( ++a ) ;
What will be the output of the above fraction of code ?
  1.    100
  2.    Displays error as ++a is not enclosed in double quotes in println statement
  3.    Compiler displays error as ++a is not a valid identifier
  4.    None of these
Answer: Option C

Check all Questions in this Topic : Click HERE

Recent Questions

Q. The Time Required To Complete A Task Is Established And A Bo....Q.  what Rate Percent Does A Man Get For His Money When In Dis....Q. Given, N = 98765432109876543210 ..... Up To 1000 Digits, Fin....Q. If A : B = 3 : 4 And B : C = 8 : 9, Then A : B : C Is = ?....Q. Which Method Enables You To Calculate Whether Daylight Savin....Q. The New Strain Of Bacteria Produced By Biotechnology In Alco....Q. In Rig Vedic Period, The Basis Of Both Social And Political ....Q.  servers Handle Requests For Other Domains....Q. If The Helix Angle Of The Drill Is Made ________ 30°, Then ....Q.  specialised Programs That Assist Users In Locating Informa....Q. Positive Income Elasticity Implies That As Income Rises, Dem....Q. The Compression Ratio Is The Ratio Of....Q. If A Load W Is Applied Instantaneously On A Bar; Then The S....Q. Work Speed Of Circular Electrode Of 220 Mm Diameter For Carr....Q. The Change Of Entropy, When Heat Is Absorbed By The Gas, Is....Q. Pick Out The Wrong Statement.....Q. Software Is:....Q. The Permissible Stress In The Fillet Weld Is 100 N/mm². The....Q. Bell Metal Is An Alloy Of....Q. Rateau Turbine Is....Q. When Current Feedback (negative) Is Applied To An Amplifier,....Q. When The Mach Number Is Between __________ The Flow Is Calle....Q. Sillimanite Is A __________ Refractory.....Q. An Ideal Traction System Should Have....Q. Which One Type Of Radiation Has The Longest Wave Length....Q. The Press-pull Tool Will ________ The Face Of A Solid Model ....Q.  during Processing Data, Programs, And Processed Informatio....Q.  digital Computers Use A ......................... System T....Q. Statement : The Company X Has Rejected First Lot Of Values S....Q. The Major Pedogenic Process Acting On Soils At The Macro Sca....Q. The Basic Purpose Of Drum In Boiler Is To....Q. In Hot Machining, Tool Is Made Of....Q. A Projectile Is Thrown At An Angle ‘α’ To The Horizonta....Q. Find Out That Word, The Spelling Of Which Is Wrong.....Q. The Radial Distance Of A Tooth From The Pitch Circle To The ....Q. A Car Moves On A Circular Path Of Radius 10 Metre. It Comple....Q. He Died In The Year 1960 At 11pm On 14 July.....Q. His Pocket Has Been Picked.....Q. In Metal Machining, The Work-tool Contact Zone Is A Zone Whe....Q. For Welding Plates Of Thickness More Than 12.5 Mm, Its Edges....Q. The Estimated Value At Which An Asset Is Expected To Be Sold....Q. Arrange The Words Given Below In A Meaningful Sequence. 1. B....Q. As Per Icao, For Airports Serving Big Aircrafts, The Crosswi....Q. A Meteor Is....Q. Find The Missing Term : 7, 8, 18, 57, ?, 1165....Q. For A Flood Control Reservoir, The Effective Storage Is Equa....Q. The Advantage Of Having A Tandem Master Cylinder Arrangement....Q. Inter-distance Between Ventilation Columns In A Sewer Line I....Q. In Each Pollen Sacs A Large Number Of Pollens Or Microspores....Q. In A Single Stage, Single Acting Reciprocating Air Compresso....