write an algorithm to add 20 and 10 and display the sum
Answers
Answered by
0
Here's an algorithm in the programming language Python to add 20 and 10 and display the sum:
# Step 1: Declare two variables to store the values 20 and 10
num1 = 20
num2 = 10
# Step 2: Calculate the sum of the two numbers
sum = num1 + num2
# Step 3: Display the sum
print("The sum of", num1, "and", num2, "is:", sum)
Similar questions
English,
1 month ago
English,
1 month ago
Math,
1 month ago
Political Science,
3 months ago
Computer Science,
3 months ago
Accountancy,
10 months ago
English,
10 months ago