Skip to content

Commit

Permalink
tem.
Browse files Browse the repository at this point in the history
  • Loading branch information
DominicRuano committed Jan 31, 2023
0 parents commit ca21b86
Show file tree
Hide file tree
Showing 7 changed files with 66 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions Estructuras condicionales aisladas.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
Binary file not shown.
27 changes: 27 additions & 0 deletions src/Main.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
public class Main {
public static void main(String[] args) {
int num1 = 8;
int num2 = 4;
int result = 0;
int val = 5;

if (val == 1){
result = num1 + num2;
System.out.println("El resultado de la suma es: " + result);
}else if (val == 2){
result = num1 - num2;
System.out.println("El resultado de la resta es: " + result);
}else if (val == 3) {
result = num1 * num2;
System.out.println("El resultado de la multiplicacion es: " + result);
}else if (val == 4) {
result = num1 / num2;
System.out.println("El resultado de la divion es: " + result);
}else {
System.out.println("La opcion elegida no existe.");
}
// System.out.println("Ingrese:\n 1 para sumar. \n 2 para restar.\n 3 para multiplicar.\n 4 para dividir." );


}
}

0 comments on commit ca21b86

Please # to comment.