Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing

  • Log In
  • Sign Up

Spaces:
KaiquanMah
/
TurkuBasicOOPinJava
Running

App Files Files Community
TurkuBasicOOPinJava / Week 3: Objects, files and exceptions
29.5 kB
Ctrl+K
Ctrl+K
  • 1 contributor
History: 14 commits
KaiquanMah's picture
KaiquanMah
String[] names = new String[16]; arr.length; list.size(); str.length();
ec3e65d verified 10 months ago
  • 1a Objects and references
    3.46 kB
    obj1.equals(obj2) 10 months ago
  • 1b. Calculator
    2.14 kB
    Create 1b. Calculator 10 months ago
  • 2. Names to list - equals
    2.05 kB
    equals 10 months ago
  • 3a. Objects as parameters and return values
    679 Bytes
    someMethod(ArrayList<Integer> list) 10 months ago
  • 3b. Add sum to list - RECREATE LIST
    2.15 kB
    ArrayList<Integer> lista = new ArrayList<>(); for (int l : pa) lista.add(l); 10 months ago
  • 4. Remove negative numbers - get, remove
    2.49 kB
    get, remove 10 months ago
  • 5a. Method side effects
    1.11 kB
    eg change order 10 months ago
  • 5b. Second smallest without side effects
    2.2 kB
    Collections.min/max, THEN go through list to find secondSmallest 10 months ago
  • 6B. Create a list
    2.04 kB
    Create 6B. Create a list 10 months ago
  • 6a. Objects as return values
    1.8 kB
    ArrayList<String> list = new ArrayList<>(); 10 months ago
  • 7. Convert to a number list
    3.06 kB
    "" + someInt; Integer.parseInt(str) 10 months ago
  • 8. Combine lists
    2.99 kB
    newList.addAll(list1); Collections.sort(newList) 10 months ago
  • 9a. Data structure - ARRAY
    3.36 kB
    String[] names = new String[16]; arr.length; list.size(); str.length(); 10 months ago