208k views
1 vote
The output for the following code will be: Pasta (1 mark)

My FavFood=Pasta
print (My FavFood)

1 Answer

5 votes

Answer:

The output is "Pasta"

Step-by-step explanation:

Given

The attached code segment

Required

The output

The first line of the program implies that:

MyFavFood="Pasta"

This means that, the value of the variable MyFavFood is string "Pasta"

Next,

print (MyFavFood)

This prints the value of the variable MyFavFood which is "Pasta"

Hence, the output is "Pasta"

User Surlac
by
6.2k points