Learning Objectives:

• understand when to use the different

print statements

• create a variable and assign it a value

• use Scanner to read in user input

• print the value of a variable using

printf




Output:

US state: Texas

Capital: Austin

The capital of Texas is Austin

Description:

Copy and paste the code below:

/*******************************************************

* Name:

* Assignment: A01

*******************************************************/


public class A01{


public static void main(String[] args){

// part1

System.out.print("x x x");

System.out.print("x o x");

System.out.print("x x x");

System.out.println();


// part2


}

}


Write your name in the comment on top. The red letters in the output are the user inputs.

This assignment consists of 2 parts.

First you demonstrate your understanding of the different print statements by modifying a

code segment. Then you read in two Strings and print a statement based on the user input.


Part1:

The code segment provided includes

three print statements that produce

the following output:


Change the code segment so that it

produces the following output:


Hint: you will need to change the number of

statements


Part2:

• Prompt the user to enter a state

• Read in the user response and assign

it to a String variable named state

Hint: before you can assign a value to the

variable state it needs to be declared

• Prompt the user to enter the name of

the capital

• Read in the user response and assign

it to a String variable named capital.

• Use printf and format specifiers to

print the following message:

The capital of state is capital

where you substitute state and capital with

the state and capital entered by the user.

Make your output look exactly like the output displayed above.

Make sure to read in the input next to the prompt but without touching it (use a blank to

separate the prompt from the user input). The output should use a single empty line to

separate the frog displayed in part1 from the output created in part2.

Answers

Answer 1

Answer:

take out the cord than put it back in than it shall work


Related Questions

Why is RAM considered as a volatile memory?​

Answers

RAM (Random Access Memory) is called volatile memory, because in RAM memory gets erased on turning off the power.......

In one to two sentences, describe how you would create a border around a group of cells.

Answers

Answer:

Select the cells you want to format. Click the down arrow beside the Borders button in the Font group on the Home tab. A drop-down menu appears, with all the border options you can apply to the cell selection.

What will print to the console after running this code segment?


A. 15.

B. 16.

C. 18.

D. 21.

Answers

Answer:

16

Explanation:

answer =3+2

answer =5+3

return 8 × 2

16 will print to the console after running this code segment. Therefore, option B is correct.

What do you mean by code segment ?

A code segment, also known as a text segment or simply text, is a section of an object file or the program's virtual address space that contains executable instructions.

A character array segment that represents a text fragment. Even though the array is directly accessible, it should be treated as immutable. This allows for quick access to text fragments without the overhead of copying around characters.

In memory, the code segment functions normally as read-only memory and has a fixed size; thus, without the need for loading, it can generally be found in read-only memory (ROM) on embedded systems.

answer = 3+2, answer = 5+3

return 8 × 2

= 16

Thus, option B is correct.

To learn more about the code segment, follow the link;

https://brainly.com/question/20063766

#SPJ2

PLEASE HELP! WILL MARK AS BRAINLIEST
JavaScript can be implemented using the _________ HTML tags in a web page.​

Answers

Answer:

JavaScript can be implemented using JavaScript statements that are placed within the ...  HTML tag

Explanation:

Imagine that your parents were starting a small business, and they wanted to upgrade their data storage. Would you recommend a fileserver, network
attached storage, or the cloud?
Why?
What are some possible disadvantages of your recommendation that they should be aware of?

Answers

Answer:

I would recommend the cloud because they can access their data on every single device. There are virtually no disadvantages to the cloud.

Explanation:

Hope this helps.

Software that enables information to be obtained from a computer without the user's knowledge is ____________

Answers

Answer:

Spyware

Explanation:

________ involves breaking into a network to steal data such as customer lists, product inventory data, employee data, and other proprietary and confidential data. (1pts) Question 5 - ________ involves breaking into a network to steal data such as customer lists, product inventory data, employee data, and other proprietary and confidential data. Pretexting Phishing Hacking Spoofing

Answers

Answer:

Hey there!

Hacking involves breaking into a network to steal data such as customer lists, product inventory data, employee data, and other proprietary and confidential data.

Hacking involves breaking into a network to steal data such as customer lists, product inventory data, employee data, and other proprietary and confidential data. Pretexting Phishing Hacking Spoofing

Hope this helped! :)

We _____ information about space. For example, while reading a textbook, we encode the place on a page where certain material appears.

Answers

Answer:

Extremes is the answer for the blank.

Explanation:

Which command should you enter at the command prompt to display the current user's quota limits and disk usage?

Answers

wmic diskdrive get size

In Linux, most applications and commands are in the ____ directory or its subdirectories bin and sbin.

Answers

On a Linux computer, most of the software applications are saved in the /usr directory or in its subdirectories named, bin and sbin.

A Linux can be defined as an open-source and community-developed operating system (OS) that is designed and developed for the following electronic devices:

Mainframes. Computers.Embedded systems.Mobile devices.

Generally, the Linux operating system (OS) is based on UNIX and it is typically released under the GNU general public license (GPL).

On a Linux computer, the commonly used directory for saving most software applications is the /usr directory or sometimes its subdirectories named, bin and sbin.

Read more: https://brainly.com/question/20629962

pretty sure nones gonna do this but please do it would gelp alot of my exams irs gonna bring me like 10 marks :(

Answers

I wanna help so bad but I failed cs

How do i add a picture on a computer? Its a random question but i dont know how to do it. It needs to be a very detailed description.

Answers

get the picture glue it on the screen

A presenter selects multimedia materials primarily based on their ability to organize data. Distract the audience. Introduce information. Emphasize a point.

Answers

Multimedia materials encompass video, audio and pictorial elements of a presentation. These materials are useful extremely useful when emphasizing a point.

In other to establish importance, emphasis has to be laid on the key points of a lesson, teaching or information.

With multimedia tools, the important points could be aired verbally, diagrammatically with annotations or using live visuals to establish the proposed points.

Learn more : https://brainly.com/question/25682762

According to the C&M Technology Competitor View, while Accenture leads in Consulting and SI, which are our two major competitors in large deals?

Answers

Even though Accenture leads in Consulting and SI, its major competitors include McKinsey and Bain & Co. Inc.

Accenture is a multinational professional technology service company that provides digital, tactical, strategic, and consulting services for its clients.

Accenture was formerly known as Arthur Anderson LLP. It's regarded as one of the top accounting firms in the world. Some of its major competitors in large deals include McKinsey, Bain & Co. Inc., Boston Consulting Group, Inc.

Read related link on:

https://brainly.com/question/25740331

what command can be used to repair a dual boot system?

Answers

Answer:

bootrec utility

Explanation:

It entirely depends on your version of windows and if you are even on windows, so I have no explanation, but for windows it is possible.

Q10: ____ server maintains a database of hostnames and their corresponding IP addresses and performs the translations automatically.

Answers

A web server is designed to maintain a database of hostnames and their corresponding IP addresses while also performing the translations of hostnames to an IP address automatically.

A server can be defined as a specialized computer system that is designed and configured to store, maintain, and provide specific remote services for its end users (clients), especially on a request basis.

In Computer and Technology, the different types of server include:

Virtual serverProxy serverApplication serverPrint serverDatabase serverFile serverWeb server

A typical function of a web server is the maintenance of a database comprising hostnames and internet protocol (IP) addresses, as well as performing the translations of hostnames to an IP address automatically.

Read more: https://brainly.com/question/21078428

Question about microscope ​

Answers

Answer:

1.  c. diaphragm

2.  a. ocular lens

3.  b. fine adjustment knob

4.  c. course adjustment knob

5.  d. nosepiece

6.  a. simple light microscope

7.  d. A, B, and C

8.  a. light switch

Explanation:

Hope this helps.

People who connect one network to another within the company or even across organizations are A. central connectors. B. boundary spanners. C. external specialists. D. peripheral specialists.

Answers

People who connect one network to another within the company or even across organizations are boundary spanners.  

People who serve as ambassadors to linking information and communications on informal networks within different department in an organisation and with other organisations or personnel  far and near for the good of their organisation are called Boundary Spanners.

The importance of Boundary  spanning in organisation includes

Exchange of expertise informationNurturing of connections with people from different part s of the world.Improved innovation in businesses

See more here: https://brainly.com/question/14728967

uploaded ads give advertisers access to more inventory than responsive display ads. true or false?

Answers

Answer:

True

Explanation:

This is because of the fact that  it allows the marketing industry rise to higher rates.

Ture but you can do that for now and then when we can get it done today and then we

___________________________________ allows many home users, corporations, and organizations around the world to connect far more computers to the Internet than they would otherwise be able to connect.

Answers

Answer:

network address translation

Explanation:

A _____ is an Access database object that allows you to arrange the fields of a record in any layout so you can enter, edit, and delete records.

Answers

A form is an access database object that allows you to arrange the fields of a record in any layout so you can enter, edit, and delete records.

The frame rate is the result of multiplying the length of the film times its width

True or False

Answers

Answer:

False

Explanation:

frame rate is how many frames are shown per second in a video

the length of the film times the width is the resolution. not frame rate

WILL MARK A BRAINLIEST!!! PLS HELP!!!





Never gonna give you up
Never gonna let you down
Never gonna run around and desert you
Never gonna make you cry
Never gonna say goodbye
Never gonna tell a lie and hurt you

Answers

Answer:

man, just got rick rolled brb going to cry

Explanation:

Daijōbu desho. Datte Kimi yowai mon.

una laptop agarra mas internet que una computadora de escritorio?

Answers

una laptop agarra mas internet que una computadora de escritorio?

Su computadora no puede afectar la velocidad de Internet de sus otros dispositivos. ... La única forma en que su computadora puede reducir la velocidad de Internet de otros dispositivos es si no obtiene suficiente velocidad de su ISP y sus dispositivos luchan por un ancho de banda limitado.

^^

translate ¨friends¨ into spanish

Answers

Friends to Spanish is Amigos

Answer: I hope this is helpful

Explanation:

Friends in Spanish is Amigo- masculine aka male ,noun.
Friend in Spanish is Amiga- feminine aka Female , noun

Friends- trusted and caring person

The ____ method constructs a text string from Unicode character codes that are passed as arguments.

Answers

Answer:

The fromCharCode() method constructs a text string from Unicode character codes that are passed as arguments.

A threat analyst is asked about malicious code indicators. Which indicator allows the threat actor's backdoor to restart if the host reboots or the us

Answers

Indicators of compromise enable system administrators and information security professionals to detect intrusion attempts or malicious activities.

Your information is incomplete as the options aren't provided. Therefore, an overview of indicators of compromise will be given.

Indicators of compromise means the pieces of forensic data that are found in files or system log entries to identify malicious activity on a network or system.

Indicators of compromise help IT and information security professionals to detect malware infections, data breaches, etc. Examples of indicators of compromise include log-in red flags, unusual outbound network traffic.

Read related link on:

https://brainly.com/question/25522987

How to fix common problem of a computer system?​

Answers

Some ways you could fix a common problem in a computer system are

Run a thorough virus scan.
Update your software.
Cut down on the bloat.
Test your Wi-Fi connection.
Reinstall the operating system.

using iot to track packages, containers, and other bulkware are examples of what type of smart iot technologies?

Answers

There are technology that are used to detect and identify objects with tracking tag. The statement is an example Smart logistics IOT technologies.

Smart logistics is commonly called Connected logistics.  It helps or allows us to have near real-time tracking of movement/delivery of goods and services.

It is often used by ECommerce companies, food delivery companies, app-based taxi service companies, online markets etc.

 

In the logistics process, Internet of things can aid an individual by tracking goods and services as it saves time.

Learn more from

https://brainly.com/question/19995128

__________ is the carrying capacity and speed of telecommunication networks that determine how much information can be sent and how fast it can travel over the networks.

Answers

Answer:

bandwidth is the carrying capacity and speed of telecommunication networks that determine how much information can be sent and how fast it can travel over the networks.

Other Questions
Can you please help me answer the questions down below. Pease read the text below to help you. Thank you so much!2. How well does Sassoon think the war is being run? Provide quotes to help explain your view.3. What is Sassoon's attitude towards the war, as shown in this extract? Provide quotes to support your view.4. How realistic is Sassoon's portrayal of England? Explain your answer.5. Why is Sassoon thinking of England in this situation?6. Give three examples of poetic techniques which have been used in this excerpt. Explain their effect on the reader.7. Based on the evidence in both extracts, what do you think a dug-out is? Escoge la frase que contiene un verbo recproco. Choose the sentence that contains a reciprocal verb. Los nios se despiertan a las 8 para la escuela. Mi familia y yo nos lavamos las manos antes de comer. Tus amigas y t siempre se besan en las mejillas cuando se encuentran. Mi familia y yo nos acostamos antes de las 10. find the value of the angles marked 'x' and 'y' Someone help me pls jessie works in an electronics store and earns a 7.5% commission on every item that she sells. How much commission would she earn for selling a computer that costs $1,580? I will mark brainliest to the correct answer. can someone help me please Punnet Squares A couple have 4 children, their first child has blood type A. the second child has blood type O. The third child has blood type AB, and the fourth has blood type B. What are the genotypes of the parents? Sequencing EventsNumber the events below in the order in which they happened.1. Italy surrenders2. Allied leaders meet at Yalta.3. German forces attack Russian city of Stalingrad.4. Invasion of Normandy by Allied forces takes place.5. President Roosevelt dies6. Soviet Army captures Berlin7. Allied troops led by General Eisenhower land in northern Africa.8. German leaders surrender unconditionally.9. Germans launch final assault in the Battle of the Buige.10. Invasion of Sicily by Allied forces. 143Time (h)2.3CarsWashed6912a. Proportional?b. Equation:C. Number of hours:3. Cars washed: Sales tax in a certain community is 7%. If the sales tax on a new car was $1,400, what was the selling price of the car Other names of Healing song Answer 5 and 6 please Which of the following statements about absolute zero is correct? who played a key role in the Hutu class becoming the rulling power in Rwanda? How did they do it? Monetary policy-makers can help smooth out the fluctuations of the business cycle by _____.examining banksreacting to current trendsimplementing inside lagspracticing good timing Write 3 different examples of the different points of view. how has the united states changed since the 1800sanswer in 1 to 2 paragraphs Please help me this is due tomorrow. A preschooler's technology skills are best developed withhours of video game practiceless exposure to computerssupport from a caregiveraudio-only lessons