commit 918d3d1509009f869d99d69c83c2f6a4f2d00278
parent 7d3db637eb7023ea21d40820b2ed52a8605e127a
Author: thing1 <thing1@seacrossedlovers.xyz>
Date: Tue, 24 Feb 2026 12:45:33 +0000
lectures from tue
Diffstat:
2 files changed, 19 insertions(+), 0 deletions(-)
diff --git a/CS10720/24.02.26.md b/CS10720/24.02.26.md
@@ -0,0 +1,3 @@
+# 24/02/24
+
+- ask what language T likes
diff --git a/CS12320/24.02.26.md b/CS12320/24.02.26.md
@@ -0,0 +1,16 @@
+# 24/02/26
+
+- you can use an ArrayList in java (linked list sorta?)
+- ArrayList is the implementation of `List` (interface) in java, which is an extension of a `Collection` in java
+- ArrayList is part of `java.util`
+- `List names = new ArrayList();`
+ - we can see it is of type `List`, as `List` is an interface
+ - we can limit the type of a List to a single type via `List<String> names = new ArrayList<>();`
+- `List` has the following methods
+ - `void add(Obj o)` appends element
+ - `int size()` gets the size
+ - `void set(int index, Obj o)` sets element at
+- Since `ArrayList` is an instate of `List`, you can create it via `ArrayList l = new ArrayList()`
+- It cant store privative data types, only objects, so you will need to put primitives into an object (boxing)
+
+- The `Collections` class is a static class containing methods to operate on a `Collection`, such as `List`