Arvutiteaduse instituut
Logi sisse
  • English
  • Kursused
  • 2016/17 sügis
  • Java alusehitus (MTAT.03.279)

Java alusehitus 2016/17 sügis

  • Pealeht
  • Loengud
  • Tulemused

Lecture 1 - Introduction

General introduction to the course. Rules of the game. Topics we'll cover. Team intro and many more!

Lecture Slides as PDF

Homework 1

Add a method to Homework class that calculates the Levenshtein distance between two strings. The signature should be public int levenshteinDistance(String a, String b). Implement at least 1 test for the method in HomeworkTest.

Feel free to use any pre-made implementation of the method! This homework is about getting the code changes, testing, packaging and submission correct and doesn't have much to do with Levenshtein distance!

Homework Feedback

  • Everybody who submitted got full points!
  • The levenshteinDistance method was actually present in StringUtils. Just to keep in mind for the future that check the libraries before going hunting for an algorithm somewhere.
    • I'm pretty sure I would have found bugs in your implementation.
    • When submitting recursive methods also keep in mind that when testing with larger datasets you might run into stack limitations.
  • If you find yourself doing a lot of very same initialisation in your tests you might want to check out the @Before annotation. See this StackOverflow post for an explanation.
  • You can have your IDE enforce a consistent style. See this StackOverflow post for example. This will keep your files looking consistent!
  • Arvutiteaduse instituut
  • Loodus- ja täppisteaduste valdkond
  • Tartu Ülikool
Tehniliste probleemide või küsimuste korral kirjuta:
Tartu Ülikooli arvutiteaduse instituudi kursuste läbiviimist toetavad järgmised programmid:
iktp regionaalarengu fondi logo euroopa sotsiaalfondi logo tiigriülikooli logo it akadeemia logo