Skip to content

Instantly share code, notes, and snippets.

@lebowvsky
Last active February 4, 2020 18:52
Show Gist options
  • Save lebowvsky/757db37f24fe9a7d2e5dc0f9561d1029 to your computer and use it in GitHub Desktop.
Save lebowvsky/757db37f24fe9a7d2e5dc0f9561d1029 to your computer and use it in GitHub Desktop.
Algorithmique et pseudo-code
réel prixBonbon
réel argent
Début calculNbreBonbons (argent, prixBonbon)
Si prixBonbon>0 ET argent>0
réel nbrBonbons=0
Si prixBonbons <= argent
Tant que nbrBonbons * prixBonbons <= argent
nbrBonbons = nbrBonbons + 1
Fin Tant que
retourner nbrBonbons
Sinon
retourner 0
Fin Si
Fin Si
Fin calculNbreBonbons
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment