1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
jeyben [28]
3 years ago
9

Write a program that creates a Date object, sets its elapsed time to 10000, 100000, 1000000, 10000000, 100000000, 1000000000, 10

000000000, and 100000000000, and displays the date and time using the toString()
Computers and Technology
1 answer:
Lady bird [3.3K]3 years ago
3 0

Answer:

Explanation:

The following Java program creates various Date objects for each one of the provided milliseconds in the question. Then it calls the toString() method on each one. The last two milliseconds were not included because as a long variable they are too big for the Date object to accept. The code has been tested and the output is shown in the image below.

import java.util.Date;

class Brainly {

   public static void main(String[] args) {

       Date date = new Date();

       date.setTime(10000);

       System.out.println(date.toString());

       Date date2 = new Date();

       date2.setTime(100000);

       System.out.println(date2.toString());

       Date date3 = new Date();

       date3.setTime(1000000);

       System.out.println(date3.toString());

       Date date4 = new Date();

       date4.setTime(10000000);

       System.out.println(date4.toString());

       Date date5 = new Date();

       date5.setTime(100000000);

       System.out.println(date5.toString());

       Date date6 = new Date();

       date6.setTime(1000000000);

       System.out.println(date6.toString());

   }

}

You might be interested in
Which is the most efficient way to include a space after each paragraph
TEA [102]

I think the question is referring to the tab key.

5 0
4 years ago
Read 2 more answers
In a relational database, a ____ would ensure that two customers with the same name don’t get confused with each other.
earnstyle [38]

Answer: Primary key

Explanation: Relational databases are those databases which are commonly found in the form of tables . It works in the relation pattern for accessing the data in the database

Primary key is a major factor which is found in the relational databases for the identification of the data in the table's column.It is considered as the unique value that corresponds to the values of rows in the table of relational database.

6 0
3 years ago
Whats worth more in adopt me- A Mega Owl or a Mega Frost Dragon?
serg [7]

Answer:

I think mega frost dragon i d k

Explanation:

6 0
2 years ago
Read 2 more answers
Can you share a google Docx. with a person who has an Icloud Email?
stiks02 [169]

Answer:

Yes, all you do is click 'share' on the top right and then copy the link, then you would send the link to said to person that has a icloud email.

5 0
3 years ago
You replaced the LCD panel in a laptop computer and verified full system functionality, including wireless connectivity. The cus
Andru [333]

Answer:

The answer would be D. The laptop's wireless radio is toggled to the off position.

Explanation:

5 0
3 years ago
Other questions:
  • A tool that is used to search for and gather data from a page on the internet is called a ?
    11·2 answers
  • How many times go you need to click the format painter button to apply copied formats to multiple paragraphs one right after the
    5·2 answers
  • A county collects property taxes on the assessed value of property, which is 60 percent of its actual value. For example, if a h
    13·1 answer
  • Which function is going to find the lowest value in a range of numbers? MIN MAXAVERAGE COUNT
    5·1 answer
  • What is the average time a caller waits for an operator to answer?
    7·1 answer
  • #Write a function called alter_list. alter_list should have#two parameters: a list of strings and a list of integers.##The list
    11·1 answer
  • Pls help me<br> first one to answer correctly gets brainly points
    6·2 answers
  • Match each proofreading mark to the expected result.
    10·1 answer
  • What are your thoughts on copyright?<br><br> (Write 2 or more sentences)
    9·2 answers
  • You can open an HTML document only in ________.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!