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
NARA [144]
3 years ago
7

What is the purpose of the following loop? int upperCaseLetters = 0; int position; String str = "abcdEfghI"; boolean found = fal

se; for (position = 0; position < str.length() && !found; position++) { char ch = str.charAt(position); if (Character.isUpperCase(ch)) { found = true; } }
Computers and Technology
1 answer:
den301095 [7]3 years ago
6 0

Answer:

See the explanation

Explanation:

Initialize a string called str and a boolean called found

Initializes a for loop that iterates through the str

Inside the for loop:

Gets the characters of the str and assigns them to the ch. Checks if the character is an uppercase or not. If an uppercase character found, updates the found as true and stops the loop.

For this example, the loop will stop when the character "E" is reached

You might be interested in
The condition known as __________ occurs when you try to store an integer that is bigger than the maximum allowed by the number
Gnoma [55]

The condition known as <u>overflow</u> occurs when you try to store an integer that is bigger than the maximum allowed by the number of bits you have.

<h3>What is a buffer?</h3>

In Computer science, a buffer can be defined as a temporary area set aside on a computer system for the storage of data. This ultimately implies that, a buffer reside in the random access memory (RAM) of a computer system.

In the event that a computer system process or software program places more data (much more than what was originally intended to be allocated for data storage) in a buffer, the extra data overflows.

In this context, we can infer and logically deduce that when a value is assigned to an integer that is too big or large for the computer to represent, it is a condition referred to as an overflow.

Read more on overflow here: brainly.com/question/26143242

#SPJ1

4 0
1 year ago
Write a program to check the password( qbasic)​
snow_tiger [21]

Answer:

Assuming this is in python:

def check_password(password):

   

   correct_password = "qbasic"

   

   if password == correct_password:

       return True

   else:

       return False

def main():

   

   user_input = input("Type in your password: ")

   

   if check_password(user_input):

       print("Correct!")

   else:

       print("Wrong, try again")

     

       

main()

Explanation:

Hope this helped :) If it wasn't suppose to be in python, tell me so I can make it in the correct programming language.

Have a good day :)

4 0
2 years ago
What character separates the file extension and the filename?
PtichkaEL [24]
A period, Filenamehere.png or .pdf or any other file extension
5 0
3 years ago
Read 2 more answers
What are the seven internal compontents of a computer
likoan [24]
Motherboard, CPU, fans, Hard drives,Power Supply,Optical Drives and RAM
4 0
3 years ago
The operating cost of driving include
blagie [28]
And what is the question?
4 0
3 years ago
Other questions:
  • To add and remove chart elements, you can use the add chart element button in the charts layout group on the ____ tab.
    6·1 answer
  • The ____ dialog box in windows vista appears each time a user attempts to perform an action that can be done only with administr
    12·1 answer
  • What is the output of the second println statement in the main method, public class foo { int i ; static int s ; public sttic vo
    15·1 answer
  • _________ is the start up sequence a computer conducts.
    9·1 answer
  • Write an expression to compute the quartic root of x. the quartic root of a number is the square root of its square root. exampl
    11·1 answer
  • What is the definition of Overflow Error?
    5·1 answer
  • What is the model for 2017 Ford Mustang v6
    15·1 answer
  • What are the two biggest strength as a student
    7·2 answers
  • What does an arrow after a command indicate
    13·2 answers
  • find_cow(name, cows) Given a name and a Python list of Cow objects, return the Cow object with the specified name. If no such Co
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!