O GoConqr está de visual novo! Conte para nós o que você achou.

Módulo 12 de 18 · Mídia

Selling ice-cream exercise

Kostas Diakogiannis

Selling ice-cream exercise

D2 - Ice Cream exercise

 

Suppose that you are working by an ice cream shop, that has waffles where you can put from 1 up to 5 balls.

Write a program that reads the number of ice creams balls the customer wants and stores it to a variable. Then calculates the cost accordingly. The prices are the following:

1 ball: 1$

2 balls: 1,8$

3 balls: 2,5$

4 balls: 3$

5 balls: 3,30$

If no balls is specified by the customer the default should be the price for 2 balls.

Print the correct price to the console at the end.

Instruções

Para avançar no curso, envie uma tentativa deste quiz. Você pode enviá-la depois da última pergunta.

Ir para o módulo escolhido

Fale Conosco

Sobre o que é sua mensagem?

O que você acha do novo visual?

Você gostou?