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
IRINA_888 [86]
2 years ago
10

(1) Prompt the user to enter two words and a number, storing each into separate variables. Then, output those three values on a

single line separated by a space. (Submit for 1 point)
Ex: If the input is:

yellow
Daisy
6
the output after the prompts is:

You entered: yellow Daisy 6
Note: User input is not part of the program output.


(2) Output two passwords using a combination of the user input. Format the passwords as shown below. (Submit for 2 points, so 3 points total).

Ex: If the input is:

yellow
Daisy
6
the output after the prompts is:

You entered: yellow Daisy 6

First password: yellow_Daisy
Second password: 6yellow6

(3) Output the length of each password (the number of characters in the strings). (Submit for 2 points, so 5 points total).

Ex: If the input is:

yellow
Daisy
6
the output after the prompts is:

You entered: yellow Daisy 6

First password: yellow_Daisy
Second password: 6yellow6

Number of characters in yellow_Daisy: 12
Number of characters in 6yellow6: 8
Computers and Technology
1 answer:
denpristay [2]2 years ago
7 0

Answer:Prompt the user to enter two words and a number, storing each into separate variables. Then, output those three values on a single line separated by a space. (Submit for 1 point) Ex: If the input is: yellow Daisy 6 the output after the prompts is: You entered: yellow Daisy 6 Note: User input is not part of the program output. (2) Output two passwords using a combination of the user input. Format the passwords as shown below. (Submit for 2 points, so 3 points total). Ex: If the input is: yellow Daisy 6 the output after the prompts is: You entered: yellow Daisy 6 First password: yellow_Daisy Second password: 6yellow6 (3) Output the length of each password (the number of characters in the strings). (Submit for 2 points, so 5 points total). Ex: If the input is: yellow Daisy 6 the output after the prompts is: You entered: yellow Daisy 6 First password: yellow_Daisy Second password: 6yellow6 Number of characters in yellow_Daisy: 12 Number of characters in 6yellow6: 8

I have tried several different ways of doing this, but I keep getting an error on line 6

Explanation:

You might be interested in
What are the two main parts to a VR experience.
Dahasolnce [82]

Answer:

The 2 main parts to a VR experience is getting comfortable and interacting with people in the VR if you have friends :3

Explanation:

:3

5 0
2 years ago
Lisa has had her California real estate license suspended for violations involving mobile homes under the California Business an
yan [13]

Answer:

Both A and B.

Explanation:

In the above statement, there some details of the question is missing that is options.

She has already had its California property license revoked under California Corporation and Occupations Law for breaches regarding mobile homes. So, she possibly she sent a check for mobile home payments to the State of California as well as the check was not honoured and she has participated knowingly in the sale of a mobile home.

7 0
3 years ago
Write a procedural programming loop.. Your loop should start variable n with a value of 10 and count down to zero. The loop shou
anastassius [24]

Answer:

//Here is the for loop in C.

for(n=10;n>0;n--)

{

   printf("count =%d \n",n);

}

Explanation:

Since C is a procedural programming language.Here if a loop that starts with n=10; It will run till n becomes 0. When n reaches to 0 then loop terminates otherwise it  print the count of n.

// here is code in C++.

#include <bits/stdc++.h>

using namespace std;

// main function

int main()

{  // variables

int n;

// for loop that runs 10 times

// when n==0 then loop terminates

for(n=10;n>0;n--)

{

   cout<<"count ="<<n<<endl;

}

return 0;

}

Output:

count =10

count =9

count =8

count =7

count =6

count =5

count =4

count =3

count =2

count =1

3 0
3 years ago
5
Tom [10]

Answer:

ما هو السؤال هنا؟

Explanation:

من فضلك أجب.

8 0
2 years ago
Read 2 more answers
A custom window shade designer charges a base fee of $50 per shade. In addition, charges are added for certain styles, sizes, an
jeka94

Answer:

Check the explanation

Explanation:

* Filename: ShadeDesigner.java

* Programmer: Jamin A. Bishop

* Date: 3/31/2012

* version 1.00 2012/4/2

*/

import java. awt.*;

import java. awt. event.*;

import java. text. DecimalFormat;

import javax. swing.*;

import javax. swing. event. ListSelectionEvent;

import javax. swing. event. ListSelectionListener;

public class ShadeDesigner extends JFrame

{

private String[] styles = {"Regular Shades", "Folding Shades", "Roman Shades"};

private String[] size = {"25 Inches Wide", "27 Inches Wide",

"32 Inches Wide", "40 Inches Wide"};

private String[] colors = {"Natural", "Blue", "Teal",

"Red", "Green"};

private JLabel banner;// To display a banner

private JPanel bannerPanel;// To hold the banner

private JPanel stylesPanel;//

private JPanel sizePanel;//

private JPanel colorPanel;

private JPanel buttonPanel;//

private JList stylesList;

private JList sizeList;

private JList colorList;

private JTextField Styles;

private JTextField Size;

private JTextField Color;

private JButton calcButton;

private JButton ExitButton;

private double totalCharges = 50.00;

//Constants

private final int ROWS = 5;

private final double regularCost = 0.00;//base price for the blinds

private final double foldingCost = 10.00;//extra cost for folding blinds

private final double romanCost = 15.00;//extra cost for roman blinds

private final double twentyfiveInCost = 0.00; //extra cost for 25" blinds

private final double twentySevenInCost = 2.00;//extra cost for 27" blinds

private final double thirtyTwoInCost = 4.00;//extra cost for 32" blinds

private final double fourtyInCost = 6.00;//extra cost for 40" blinds

private final double naturalColorCost = 5.00;//extra cost for color

public ShadeDesigner()

{

//display a title

setTitle("Shade Designer");

// Specify what happens when the close button is clicked.

setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

// Create the banner on a panel and add it to the North region.

buildBannerPanel();

add(bannerPanel, BorderLayout. NORTH);

stylesPanel();

add(stylesPanel, BorderLayout. WEST);

sizePanel();

add(sizePanel, BorderLayout. CENTER);

colorPanel();

add(colorPanel, BorderLayout. EAST);

buttonPanel();

add(buttonPanel, BorderLayout. SOUTH);

pack();

setVisible(true);

}

//build the bannerpanel

private void buildBannerPanel()

{

bannerPanel = new JPanel();

bannerPanel.setLayout(new FlowLayout(FlowLayout.CENTER));

banner = new JLabel("Shade Designer");

banner.setFont(new Font("SanSerif", Font.BOLD, 24));

bannerPanel.add(banner);

}

//stylepanel

private void stylesPanel()

{

JLabel styleTitle = new JLabel("Select a Style.");

stylesPanel = new JPanel();

stylesPanel. setBorder(BorderFactory. createEmptyBorder(5,5,5,5));

stylesList = new JList (styles);

stylesList.setVisibleRowCount(ROWS);

JScrollPane stylesScrollPane = new JScrollPane(stylesList);

stylesList. setSelectionMode(ListSelectionModel.SINGLE_SELECTION);

stylesList. addListSelectionListener(new stylesListListener());

stylesPanel. setLayout(new BorderLayout());

stylesPanel. add(styleTitle, BorderLayout. NORTH);

stylesPanel. add(stylesScrollPane, BorderLayout. CENTER);

Styles = new JTextField (5);

Styles. setEditable(false);

//stylesPanel. add(StylesLabel, BorderLayout. CENTER);

stylesPanel. add(Styles, BorderLayout. SOUTH);

}

private class stylesListListener implements ListSelectionListener

{

public void valueChanged (ListSelectionEvent e)

{

String selection = (String) stylesList. getSelectedValue();

Styles. setText(selection);

}

}

//size panel

private void sizePanel()

{

JLabel sizeTitle = new JLabel("Select a Size.");

sizePanel = new JPanel();

sizePanel. setBorder(BorderFactory. createEmptyBorder(5,5,5,5));

sizeList = new JList (size);

sizeList.setVisibleRowCount(ROWS);

JScrollPane stylesScrollPane = new JScrollPane(sizeList);

sizeList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);

sizeList.addListSelectionListener(new sizeListListener());

sizePanel. setLayout(new BorderLayout());

sizePanel. add(sizeTitle, BorderLayout. NORTH);

sizePanel. add(stylesScrollPane, BorderLayout. CENTER);

//sizeLabel = new JLabel("Style Selected: ");

Size = new JTextField (5);

Size.setEditable(false);

//stylesPanel. add(StylesLabel, BorderLayout. CENTER);

sizePanel. add(Size, BorderLayout. SOUTH);

}

private class sizeListListener implements ListSelectionListener

{

public void valueChanged (ListSelectionEvent e)

{

String selection = (String) sizeList. getSelectedValue();

Size. setText(selection);

}

}

6 0
3 years ago
Other questions:
  • Will give brainliest!!!!!!!!!!!!
    6·2 answers
  • Write a copy constructor for carcounter that assigns origcarcounter.carcount to the constructed object's carcount. sample output
    15·2 answers
  • What was the first Apple computer, and who was it designed by?
    7·2 answers
  • You are the administrator of a Windows network. When creating a new user account, you specify a security clearance level of top
    8·1 answer
  • A(n) ________ operator, such as the greater than or less than symbol, can be used in a query criterion to limits the results pro
    12·2 answers
  • Users of Adobe Reader, created by Adobe Systems Incorporated, are prompted to provide feedback on their experiences with the sof
    7·1 answer
  • State the difference between = and ==
    9·1 answer
  • Write a program that prompts the user to enter a series of numbers between 0 and 10 asintegers. The user will enter all numbers
    6·1 answer
  • Bob The Penguin is a real you-tuber, and he plays Mine-craft. Who is his owner?
    6·1 answer
  • PLEASE HELP ME
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!