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
VikaD [51]
3 years ago
13

A and B have same output or not? A B x=0 x=0 do do x<3 x=x+1 x=x+1 print x print x while x<3 while

Computers and Technology
1 answer:
katen-ka-za [31]3 years ago
6 0

Answer:

A and B have different output:

A output will be 1

B output will be 123

Explanation:

A

X = 0

do x < 3

x = x+1

print x

while

B

X = 0

do x = x+ 1

print x

while x < 3

For statement A the condition statement which suppose to be after "while" is not set therefore the value of x will be printed.

For statement B the condition statement is set "x < 3" in front of "while" thereby result in iteration until the condition is false.

Statement A output will be 1

Statement B output will be 123

You might be interested in
Can someone please explain binary addition to me? i have a test tomorrow yikes
umka2103 [35]

Answer:

its easy

Explanation:

there are are 5 main rules

in binary there are 2 number 0 and 1

0 + 0 = 0

0 + 1 = 1

1+0=1

1+1=0 carry 1

e . g

1 1 1

1 0 1 0 1 0

+ 1 1 0 0 1 0

-------------------------

1 1 1 1 1 0 0

*in bold are the ones that you need to carry.

in decimal there are 10 possible numbers 0- 9

when you do 1 + 9 it becomes 10, this can be done easily, however if you do 1 + 9 in a table like above, you will get 0 for the first column and you will carry 1 to the next column .

in binary is the same idea but using on 2 numbers 1 and 0

e.g

1

1

+ 9

----------

1 0

*in bold are the ones that you need to carry.

hope it helps and good luck in your exam.

3 0
3 years ago
Which best explains the relationship among these three facts question 8
makvit [3.9K]

Answer:

no attachment

Explanation:

8 0
3 years ago
Click this link to view O*NET's Skills section for Biomedical Engineers. Note that common skills are listed toward the top and l
Phoenix [80]

Answer:

Science

complex problem solving

critical thinking

judgment and decision making

Explanation:

im on endunety

7 0
3 years ago
Read 2 more answers
What will the following code snippet print out? class Raspberry extends Fruit implements Boxable { ... } Raspberry berry = new R
sveticcg [70]

Answer:

The answer to this question is "TrueTrueTrueTrue".

Explanation:

In the java program code firstly we declare the class that is Fruit and an interface that is Boxable. In the class and interface, we write some code. Then we declare another class that is Raspberry. for class to class inherit we use the extends keyword and class to interface inherit we use the implements keyword. Then we create a Raspberry class object that is berry. and use the print command or method that is (System.out.println). In this, we write some code and run it. So the output of the program is true because all the code that is written in the method is correct.  

3 0
4 years ago
Dữ liệu trong 1CSDL được lưu trong
White raven [17]

Answer:

ha ano daww??

Explanation:

??? btw thanks for the points

5 0
3 years ago
Read 2 more answers
Other questions:
  • When it comes to saving money, what is a good rule of thumb?
    5·2 answers
  • • Describe the steps in detail that the operating system performs to handle interrupts, including ISRs, the stack, and hardware?
    5·1 answer
  • What financial behaviors will typically lead to a low credit score?
    14·1 answer
  • Keyboards that are widely used on various smartphones and other small portable devices, and which are designed primarily for com
    15·1 answer
  • ¿por que la toria de lamarck sobre el alargamiento del cuello de las jirafas por el esfuerzo continuado no pasara a sus descendi
    10·1 answer
  • Pls help computer science I will give brainliest
    8·2 answers
  • How would you describe the difference between a syntax error and a logic error?
    13·2 answers
  • How would you delete a slide from your presentation after selecting it?
    14·1 answer
  • How many times is the body of the loop executed?
    8·1 answer
  • Structured query language (sql) enables data analysts to _____ the information in a database.
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!