Menu
Question Index
...

Assume that the date is 01/23/2014, time is 9H 54M 36S, ISTzone and the day is Thursday. Then what could be the output of the following program?

import java.util.*;
public class TestSkill {
    public static void main(String args[]) {
        Date dNow = new Date();
        System.out.println("Current Date: " + (dNow));
    }
}


Current Date: Thu Jan 23 2014 09:54
Current Date: Jan 23 2014
Current Date: Thu Jan 23 09:54:36 IST 2014
Compilation Error or Runtime Error

Doubts

Problems

Topic: Java Date Class

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App