Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
main.cpp
- Committer:
- yiato
- Date:
- 2020-04-03
- Revision:
- 1:0b9be892ceaf
- Parent:
- 0:f8d824abdf66
- Child:
- 2:976e71d7270c
File content as of revision 1:0b9be892ceaf:
#include "mbed.h"
//programa que genera una función con argumentos y con retorno de valor
Serial com1(USBTX, USBRX);
int suma(int a, int b); //declaración de funcion
int main()
{
int suma(int a, int b);
}
int suma(int a, int b)
{
int variable1, variable2, suma;
variable1=10;
variable2=4;
suma= variable1 + variable2 ;
while(1);
{
com1.printf("la suma es igual a %d \n", suma);
wait(1);
}
return (suma);
}