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
lys-0071 [83]
3 years ago
7

Assign the size of userInput to stringSize. Ex: if userInput is "Hello", output is: Size of userInput: 5

Computers and Technology
1 answer:
Basile [38]3 years ago
8 0

Answer:

import java.util.Scanner;

public class StringSize {

  public static void main (String [] args) {

     Scanner scnr = new Scanner(System.in);

     String userInput;

     int stringSize;

     userInput = scnr.nextLine();

     

     /* Your solution goes here  */

     

     stringSize = userInput.length();

     

     System.out.println("Size of userInput: " + stringSize);

     return;

  }

}

Explanation:

stringSize = userInput.length();  //  userInput.length() will get the length of the string and  put in stringSize

You might be interested in
What are the other way of getting website static​
erica [24]

Answer:

Explanation: Jekyll. Jekyll is far and away the most popular static site generator. ...

Hexo. Hexo is a build tool created with nodeJS, which allows for super speedy rendering, even with extremely large sites

and Hugo

I hope this help =D

7 0
3 years ago
Read 2 more answers
Draw a flowchart and write pseudocode to represent the logic of a program that allows the user to enter values for the width and
n200080 [17]

Answer:

10. Start

20. Enter Width of the room (W)

30. Enter length of the room (L)

40. LET Area = L * W

50. Output Area

60. End

Explanation:

The flowchart is attached to this answer as an attachment.

7 0
4 years ago
On Study Island, What do I do when the numbers don't show up?
mafiozo [28]
Try restarting your laptop
8 0
3 years ago
Read 2 more answers
Dave is a recruiter for a large video and animation firm. He is looking for an employee who is willing to give productive hours
kumpel [21]

Answer:

reliabitlity

Explanation:

3 0
3 years ago
What is your robloz?​
ira [324]

Answer:

my Ro.b.l.o.x is cookiefunny232

Explanation:

5 0
3 years ago
Other questions:
  • Write a program that prompts the user for the shift value (e.g. 3) and then a plain-text message to encode. Encrypt the message
    5·1 answer
  • Write the header for a function addOne that accepts a single integer reference parameter and returns nothing. Name the parameter
    5·1 answer
  • Count characters Write a program whose input is a string which contains a character and a phrase, and whose output indicates the
    6·1 answer
  • PLS ANSWER ASAP I WILL GIVE BRAINLIEST
    11·1 answer
  • A filter is limited to extracting data from a single table. <br> a. True <br> b. False
    9·1 answer
  • What a promblem Hypothesis<br>​
    8·2 answers
  • Plagiarism occurs when writers
    14·2 answers
  • List and briefly explain four common template elements
    6·1 answer
  • A large number of consecutive IP addresses are available starting at 198.16.0.0. Suppose that four organizations, Able, Baker, C
    11·1 answer
  • Which 4 elements are commonly contained in a master page?
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!