Ask Question
11 April, 17:20

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

+3
Answers (1)
  1. 11 April, 20:53
    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");

    }
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Write a program that assigns two integer values from standard input to the variables int1 and int2, then prints "true" if they are equal, ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers