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
Ne4ueva [31]
4 years ago
8

Assume the variable date has been set to a string value of the form mm/dd/yyyy, for example 09/08/2010. (Actual numbers would ap

pear in the string.) Write a statement to assign to a variable named dayStr the characters in date that contain the day. Then set a variable day to the integer value corresponding to the two digits in dayStr.
Computers and Technology
1 answer:
bonufazy [111]4 years ago
6 0

Answer:

String date = "21/05/2020";

String dayStr = date.substring(0,2);

int day = Integer.parseInt(dayStr);

System.out.println(day);

Explanation:

Create a variable called <em>date</em> which holds the current date

Create a variable called <em>dayStr</em>. Initialize it to the day part of the <em>date</em> using the substring method

Create a variable called <em>day</em>. Parse the <em>dayStr</em> and assign it to the <em>day</em>

Print the <em>day</em>

You might be interested in
How todraw a status bar​
emmainna [20.7K]
I did some research and I found this but I don’t think it helped When the drawing status bar is turned on it displays at the bottom of the drawing area. When the drawing status bar is turned off, the tools found on the drawing status bar are moved to the application status bar.
When the drawing status bar is turned on, you can use the Infobar menu to choose which tools display in status bar.
3 0
3 years ago
How has the Aswan High Dem had an adverse effect on human health?​
Lorico [155]

Answer:

How was the Aswan high dam had an adverse effect on human health? It created new ecosystems in which diseases such as malaria flourished. An environmental challenge facing the Great Man Made River is that pumping water near the coast. ... Water scarcity makes it impossible to grow enough food for the population.

Explanation:

7 0
3 years ago
Which is considered the best way to secure a laptop to a desk in a workplace?
Lorico [155]

Answer:

Lock it in a safe is the best way to secure a  laptop to a  desk in a work space.

Explanation:

Since the end user feels that a laptop can be stolen or taken by others is a safe way to keep hire or her laptop in a  safe place.

Bolt  it:-  it is  not possible, because there   is  no   option available

Lock  it is safe:- this  is  idle or best  solution is  safe his or her laptop

Use an alarm :- the person   who steals the laptop will be more intelligent and he or she knows how to disable the alarm system.

Use  cable lock;- it is easy to remove it.

3 0
3 years ago
Dreams is Littlebigplanet 4, change my mind.
kodGreya [7K]

Answer:

It looks like a bean

Explanation:

6 0
3 years ago
An animal shelter recently held an adoption event and found homes for 48 of their shelter animals. If they found home for 80% of
vredina [299]

Answer:

9.6

Explanation:

4 0
3 years ago
Read 2 more answers
Other questions:
  • Which of these decisions would u most likely make on ur own
    8·2 answers
  • You are the project manger for Xylophone Phonics. It produces children's software programs that teach basic reading and math ski
    11·1 answer
  • What would be the results of the following code? final int SIZE = 25; int[] array1 = new int[SIZE]; … // Code that will put valu
    9·1 answer
  • Write a do-while loop that asks the user to enter two numbers. The numbers should be added and the sum displayed. The user shoul
    13·1 answer
  • A company wants to inform a select list of it's regular customers about a flash sale. Which type of platform will it use to send
    9·1 answer
  • Most operating systems perform all of the following tasks except _____. a. displaying the Graphical User Interface b. indexing t
    13·1 answer
  • Any one have a snnaap chhhaatt if so i need help with something n there
    15·2 answers
  • How many sections of a job description are there
    5·1 answer
  • The CTRL, ALT, and WINDOWS keys are commonly used for keyboard shortcuts, which are keystrokes that can quickly perform an opera
    9·1 answer
  • Write algorithm and flowchart for the following<br>a.find the sum and average of any four numbers ​
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!