sukhveerchani sukhveerchani
  • 14-06-2020
  • Computers and Technology
contestada

write a python program to initialize the value of two variables then find sum

Respuesta :

Аноним Аноним
  • 14-06-2020

Answer:

JavaScript:

Let x = 10

Let y = 10

Console.log(x + y)

//outputs 20

C++:

Let x = 10

Let y = 10

The file is Math.cpp so,

std::cout << "" + y + "" + x

g++ Math.cpp -o Maths

./Maths

//Outputs 20

Answer Link
hello1222 hello1222
  • 14-06-2020

Answer:

#Ask the user for a number

a = int(input("Enter a number: "))

#Ask the user for a number

b = int(input("Enter a number: "))

#Calculate the sum of a and b

sum = a + b

#print the ouput

print(str(a) + " + " + str(b) + " = " + str(sum))

Answer Link

Otras preguntas

Each side of a square is (7 + 3x) units. Which is the perimeter of the square?
Which type of promotion happens in informal conversations?
The two "fathers" of modern geology lived during the _____. 16-1700's 17-1800's 18-1900's
Read the paragraph. In describing the woman's beauty, Byron writes, "And all that's best of dark and bright / Meet in her aspect and her eyes." At the end of th
A dragonfly can beat its wings 30 times per second. Write an equation in slope-intercept form that shows the relationship between flying time in seconds and the
which fraction shows a correct way to set up the slope
Fractions that are equal to 6/8
What is 5 facts about atmessphere?
True or false? the risk of investing in junk bonds is usually lower than the risk of investing in cds.
In a _____________ arrangement two part-time employees fill one full-time job. job enlargement multitasking job sharing split shift