Skip to content

Instantly share code, notes, and snippets.

@samueltcsantos
Created November 17, 2014 21:14
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save samueltcsantos/7d91aa4474df3e5bdbeb to your computer and use it in GitHub Desktop.
Save samueltcsantos/7d91aa4474df3e5bdbeb to your computer and use it in GitHub Desktop.
Converter Farenheit para Celsius em visualg.
algoritmo "farenheitCelsius"
// Função : Faça um Programa que peça a temperatura em graus Farenheit,
// transforme e mostre a temperatura em graus Celsius.
// C = (5 * (F-32) / 9).
// Autor : Samuel T. C. Santos
// Data : 17/11/2014
// Seção de Declarações
var
celsius , farenheit : real
inicio
// Seção de Comandos
escreva("Farenheit? ")
leia(farenheit)
celsius <- 5 * (farenheit - 32) / 9
escreval("celsius = ", celsius)
fimalgoritmo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment