Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
E
EinfacheUebungZuDynamischenDatenstrukturen
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
AlfaTrainingKurse
Java
EinfacheUebungZuDynamischenDatenstrukturen
Commits
c4c2b9c8
Commit
c4c2b9c8
authored
5 years ago
by
Dennis Eisold
Browse files
Options
Downloads
Patches
Plain Diff
Initial commit
parents
No related branches found
No related tags found
No related merge requests found
Pipeline
#111
failed with stages
in 18 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
EinfacheUebungZuDynamischenDatenstrukturen.iml
+12
-0
12 additions, 0 deletions
EinfacheUebungZuDynamischenDatenstrukturen.iml
src/de/itstall/Main.java
+60
-0
60 additions, 0 deletions
src/de/itstall/Main.java
with
72 additions
and
0 deletions
EinfacheUebungZuDynamischenDatenstrukturen.iml
0 → 100755
+
12
−
0
View file @
c4c2b9c8
<?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>
This diff is collapsed.
Click to expand it.
src/de/itstall/Main.java
0 → 100755
+
60
−
0
View file @
c4c2b9c8
package
de.itstall
;
import
java.util.ArrayList
;
import
java.util.TreeMap
;
public
class
Main
{
public
static
void
main
(
String
[]
args
)
{
/* Aufgabe 1 */
ArrayList
<
Integer
>
ialNumbers
=
new
ArrayList
<
Integer
>();
/* Aufgabe 2 */
ialNumbers
.
add
(
13
);
ialNumbers
.
add
(
24
);
ialNumbers
.
add
(
123
);
/* Aufgabe 3 */
System
.
out
.
println
(
ialNumbers
.
toString
());
/* Aufgabe 4 */
TreeMap
<
Integer
,
String
>
tm
=
new
TreeMap
<
Integer
,
String
>();
/* Aufgabe 5 */
tm
.
put
(
10
,
"Zehn"
);
tm
.
put
(
20
,
"Zwanzig"
);
tm
.
put
(
50
,
"Fünfzig"
);
tm
.
put
(
40
,
"Vierzig"
);
/* Aufgabe 6 */
System
.
out
.
println
(
tm
);
/* Aufgabe 7 */
TreeMap
<
Integer
,
ArrayList
>
Ag7
=
new
TreeMap
<
Integer
,
ArrayList
>();
/* Aufgabe 8 */
ArrayList
<
String
>
al1
=
new
ArrayList
<>();
ArrayList
<
String
>
al2
=
new
ArrayList
<>();
ArrayList
<
String
>
al3
=
new
ArrayList
<>();
ArrayList
<
String
>
al4
=
new
ArrayList
<>();
al1
.
add
(
"Zehn"
);
al1
.
add
(
"Ten"
);
Ag7
.
put
(
10
,
al1
);
al2
.
add
(
"Zwanzig"
);
al2
.
add
(
"Tewnty"
);
Ag7
.
put
(
20
,
al2
);
al3
.
add
(
"Fünfzig"
);
al3
.
add
(
"Fifty"
);
Ag7
.
put
(
50
,
al3
);
al4
.
add
(
"Vierzig"
);
al4
.
add
(
"Fourty"
);
Ag7
.
put
(
40
,
al4
);
/* Aufgabe 9 */
System
.
out
.
println
(
Ag7
);
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment