Created
February 6, 2025 18:46
-
-
Save ReyesRamirez/8e36035efdcf0524db56481130d2a241 to your computer and use it in GitHub Desktop.
Ejemplo funcion flecha
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Funciones basicas que devuelven valor, | |
// y ejecuta las instrucciones entre llaves | |
int resta(int a, int b){ | |
return a-b; | |
} | |
// funcion flecha | |
int flecharesta(int a, int b) => a-b; | |
void main() { | |
print(" Reyes Ramirez 22308051201289"); | |
int x = 9; | |
int y = 3; | |
print(" funcion resta normal "); | |
int r= resta(x,y); | |
print("La resta de $x - $y es $r"); | |
print(" funcion resta tipo flecha "); | |
int r1=flecharesta(12,2); | |
print("La resta de flecharesta(12,2) es $r1"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Salida el ejemplo flecha resta