AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

This commit is contained in:
Jacob Signorovitch
2025-02-13 10:55:21 -05:00
parent f26b576c99
commit 7ac3142974
3 changed files with 28 additions and 2 deletions

View File

@@ -14,4 +14,15 @@
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
<filteredResources>
<filter>
<id>1739196678733</id>
<name></name>
<type>30</type>
<matcher>
<id>org.eclipse.core.resources.regexFilterMatcher</id>
<arguments>node_modules|\.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__</arguments>
</matcher>
</filter>
</filteredResources>
</projectDescription>

View File

@@ -1,3 +1,15 @@
package arrays;
class Sieve implements Iterator<T> {}
import java.util.Iterator;
import tester.Tester;
class Sieve implements Iterator<Integer> {
public boolean hasNext() { return false; }
public Integer next() { return null; }
}
class Examples {
Iterator<Integer> i = new Sieve();
}

View File

@@ -178,6 +178,7 @@ class BFT<X> implements Iterator<X> {
}
}
/*
class TreeFinder {
// Know the first element of the preorder list will be the root node of the
// tree. Assuming node values are unique, you can then locate that node in
@@ -185,7 +186,6 @@ class TreeFinder {
// subtree, the ones to the right on the right. Repeat the process on the
// subtreees.
// Learned you can do static methods with a type like this :).
static <T> BT<T> find(ArrayList<T> inorder, ArrayList<T> preorder) {
int inorderRootIdx = inorder.indexOf(preorder.getFirst());
System.out.println(inorderRootIdx);
@@ -238,6 +238,7 @@ class TreeFinder {
return new Node<>(val, leftTree, rightTree);
}
}
*/
class Examples {
BT<Integer> tree;
@@ -297,6 +298,7 @@ class Examples {
);
}
/*
void testTreeFinder(Tester t) {
init();
@@ -313,4 +315,5 @@ class Examples {
t.checkExpect(found, tree);
}
*/
}