@@ -0,0 +1,29 @@ | |||
### IntelliJ IDEA ### | |||
out/ | |||
!**/src/main/**/out/ | |||
!**/src/test/**/out/ | |||
### Eclipse ### | |||
.apt_generated | |||
.classpath | |||
.factorypath | |||
.project | |||
.settings | |||
.springBeans | |||
.sts4-cache | |||
bin/ | |||
!**/src/main/**/bin/ | |||
!**/src/test/**/bin/ | |||
### NetBeans ### | |||
/nbproject/private/ | |||
/nbbuild/ | |||
/dist/ | |||
/nbdist/ | |||
/.nb-gradle/ | |||
### VS Code ### | |||
.vscode/ | |||
### Mac OS ### | |||
.DS_Store |
@@ -0,0 +1,8 @@ | |||
# Default ignored files | |||
/shelf/ | |||
/workspace.xml | |||
# Editor-based HTTP Client requests | |||
/httpRequests/ | |||
# Datasource local storage ignored files | |||
/dataSources/ | |||
/dataSources.local.xml |
@@ -0,0 +1,6 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> | |||
<project version="4"> | |||
<component name="ProjectRootManager" version="2" project-jdk-name="openjdk-23" project-jdk-type="JavaSDK"> | |||
<output url="file://$PROJECT_DIR$/out" /> | |||
</component> | |||
</project> |
@@ -0,0 +1,8 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> | |||
<project version="4"> | |||
<component name="ProjectModuleManager"> | |||
<modules> | |||
<module fileurl="file://$PROJECT_DIR$/prog3.iml" filepath="$PROJECT_DIR$/prog3.iml" /> | |||
</modules> | |||
</component> | |||
</project> |
@@ -0,0 +1,15 @@ | |||
//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or | |||
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter. | |||
public class Main { | |||
public static void main(String[] args) { | |||
//TIP Press <shortcut actionId="ShowIntentionActions"/> with your caret at the highlighted text | |||
// to see how IntelliJ IDEA suggests fixing it. | |||
System.out.printf("Hello and welcome!"); | |||
for (int i = 1; i <= 5; i++) { | |||
//TIP Press <shortcut actionId="Debug"/> to start debugging your code. We have set one <icon src="AllIcons.Debugger.Db_set_breakpoint"/> breakpoint | |||
// for you, but you can always add more by pressing <shortcut actionId="ToggleLineBreakpoint"/>. | |||
System.out.println("i = " + i); | |||
} | |||
} | |||
} |
@@ -0,0 +1,5 @@ | |||
public class helloWorld { | |||
public static void main (String[] args){ | |||
System.out.println("Hello World!"); | |||
} | |||
} |
@@ -0,0 +1,26 @@ | |||
package praktikum01; | |||
public class Zahlenfelder { | |||
public static void main(String[] args) { | |||
for (int i = 1; i < 201; i++) { | |||
// Wenn durch 5 Teilbar | |||
if (i % 5 == 0) { | |||
System.out.println(i + " - <Zahl> ist durch 5 Teilbar"); | |||
} | |||
wennEndeGleichNeun(i); | |||
} | |||
} | |||
public static void wennEndeGleichNeun(int i){ | |||
// Wenn Zahl auf 9 endet | |||
if (i % 10 == 9) { | |||
System.out.println(i + " - <Zahl> endet auf 9"); | |||
} | |||
} | |||
} | |||