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
svp [43]
3 years ago
10

Write a program that assigns two integer values from standard input to the variables int1 and int2, then prints "true" if they a

re equal, and "false" if they are not. submit
Computers and Technology
1 answer:
Gwar [14]3 years ago
7 0
C# program code:

int int1;
int int2;
Console.WriteLine("Insert first number");
int1 = Console.ReadLine();
Console.WriteLine("Insert second number");
int2 = Console.ReadLine();
if (int1 == int2)
{
Console.WriteLine("true");
}
else
{
Console.WriteLine("false");
}
You might be interested in
Write a program that will print out statistics for eight coin tosses. The user will input either an "h" for heads or a "t" for t
shusha [124]

Answer:

Written in Python

head = 0

tail = 0

for i in range(1,9):

     print("Toss "+str(i)+": ")

     toss = input()

     if(toss == 'h'):

           head = head + 1

     else:

           tail = tail + 1

print("Number of head: "+str(head))

print("Number of tail: "+str(tail))

print("Percent head: "+str(head * 100/8))

print("Percent tail: "+str(tail * 100/8))

Explanation:

The next two lines initialize head and tail to 0, respectively

head = 0

tail = 0

The following is an iteration for 1 to 8

<em>for i in range(1,9): </em>

<em>      print("Toss "+str(i)+": ") </em>

<em>      toss = input()  </em><em>This line gets user input</em>

<em>      if(toss == 'h'):  </em><em>This line checks if input is h</em>

<em>            head = head + 1 </em>

<em>      else:  </em><em>This line checks otherwise</em>

<em>            tail = tail + 1 </em>

The next two lines print the number of heads and tails respectively

print("Number of head: "+str(head))

print("Number of tail: "+str(tail))

The next two lines print the percentage of heads and tails respectively

print("Percent head: "+str(head * 100/8))

print("Percent tail: "+str(tail * 100/8))

3 0
3 years ago
_____ separation strategies (e.g., attacking and sabotaging others) are used by those for whom co-cultural segregation is an imp
soldier1979 [14.2K]

Answer: Aggressive

Explanation:

Aggressive separation strategies are the technique that involves confrontation and intense feeling for separating something from others.

  • This technique includes action like attacking, assaultive, confronting etc.for segregation.
  • Co-culture segregation is separation of a subset of culture from large and major culture.In this culture, there can be more than two types of culture that are split forcefully through barrier.
  • Thus, co-culture segregation uses the methodology of aggressive separation.

5 0
3 years ago
How to calculate least count of a stopwatch
Nimfa-mama [501]
Look. You need to stop your watch at 00:00. And then you'll see that its least count is 0.01 second and then you should add your clocks' response time to make results more accurate.
8 0
2 years ago
I need help fixing this please
Shkiper50 [21]

Explanation:

I think that you might have used it a lot or its just a glitch and will come back after some time.

It might be that your screen cracked.

But try re-booting if that does not work, wait and take off the battery.

5 0
2 years ago
Read 2 more answers
Which tools is used to bundle cables neatly inside and outside of a computer?​
Ugo [173]

Answer:

Cable Ties

Explanation:

6 0
3 years ago
Other questions:
  • Chdtp aoxophg gr72 ae9&gt;3 zqqz
    12·1 answer
  • You would like to search for information about storms but not tornadoes. What type of search strategy may be useful?
    10·2 answers
  • Many computer magazines and Web sites present comparisons of several DBMSs. Find one such DBMS comparison article and compare th
    10·1 answer
  • Your boss bought a new printer with a USB 3.0 port, and it came with a USB 3.0 cable. Your boss asks you:
    7·2 answers
  • A(n) _________ is a computer system which is part of a larger system which performs a dedicated function.
    8·1 answer
  • The function below takes a single argument: data_list, a list containing a mix of strings and numbers. The function tries to use
    6·1 answer
  • What does the following code segment do?
    13·1 answer
  • Pls explain the meaning of the word"INTERNET"​
    5·2 answers
  • Which of the following keywords allows a subclass to access a superclass method even when the subclass has overridden the superc
    9·1 answer
  • The development of online capabilities created the ________, an information- and communication-based electronic exchange environ
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!