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
Alex17521 [72]
3 years ago
5

write a java program using a do while loop to prompt the user to enter a password. The user should be prompted to enter the pass

word until the correct password "pals" is entered.
Computers and Technology
1 answer:
Alex787 [66]3 years ago
3 0
We can import Scanner from Java.utils.Scanner to pull in text entered in the console.

public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String password = "";
do {
System.out.print("Enter your password: ");
password = sc.nextLine();
if(!password.equals("pals") {
System.out.println(\nIncorrect Password. Try again.");
}
} while(!password.equals("pals");
You might be interested in
In Tynker, it is not possible to create a/an __________.
xz_007 [3.2K]

Answer:

yes

Explanation:

7 0
2 years ago
Read 2 more answers
What is considered any computer system that isn't a general-purpose pc or server?
Kay [80]

Embedded system is considered any computer system that isn't a general-purpose pc or server.

<h3>What is an embedded system?</h3>

An embedded system is a combination of computer hardware and software designed for a specific function. Embedded systems may also function within a larger system. The systems can be programmable or have a fixed functionality.

<h3>What is embedded system and its types?</h3>

Embedded systems comprise hardware and software that work together to perform specific tasks. They rely on microprocessors, microcontrollers, memory, input/output communication interfaces, and a power supply to function

To learn more about embedded system, refer

brainly.com/question/13014225

#SPJ4

3 0
2 years ago
Initialize the tuple team_names with the strings 'Rockets', 'Raptors', 'Warriors', and 'Celtics' (The top-4 2018 NBA teams at th
dexar [7]

Answer:

Following is the code in python language

team_names = ('Rockets','Raptors','Warriors','Celtics')#holding the string value

print(team_names[0],team_names[1],team_names[2],team_names[3])#display

Output:

Rockets Raptors Warriors Celtics

Explanation:

Following is the description of above statement .

  • Create a dictionary "team_names" that is holding the string value Rockets Raptors Warriors and Celtics.
  • Finally we used the print function in that function we pass the index of corresponding dictionary i.e team_names[0] . it will display the first index value  similarly we pass  team_names[1], team_names[2]  team_names[3].
8 0
3 years ago
Within the seven domains of a typical IT infrastructure, there are particular roles responsible for data handling and data quali
nikitadnepr [17]

Answer:

The answer is "auditors"

Explanation:

Description to this question can be described as follows:

  • Auditors are professionals who analyze business and corporate accounts to determine, that the financial reports are accurate and lawful. It will serve as a consultant to suggest possible measures for risk avoidance or cost reduction.
  • Data security is the mechanism to avoid theft, loss of sensitive information, and information quality is critical and it is not able to know or stay in contact with your clients without high-quality data, that's why auditors are the correct answer and other choices can't be defined in the following senior.
7 0
3 years ago
Select the correct answer.
S_A_V [24]
I think the answer is b
5 0
3 years ago
Other questions:
  • Failure to verify information can lead to?
    10·1 answer
  • In procedural programming, where does the flow of control usually route from the main function?
    8·1 answer
  • Which routine best ensures email safety?
    7·2 answers
  • What does "FDDI" stand for in Technology?
    5·2 answers
  • How to simplify???? 2(-3x^2+6x+1)-2(4x^2-3x+1)<br><br>​
    7·1 answer
  • Explain motherboard in detail
    14·2 answers
  • Write a statement to add the key Tesla with value USA to car_makers. Modify the car maker of Fiat to Italy. Sample output for th
    13·1 answer
  • Which of the following is not true?A. An organization may express its cybersecurity state through a Current Profile to report re
    10·1 answer
  • Using an outline, how do you maintain your computer or cellphone​
    8·1 answer
  • Question:
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!