Giter Club home page Giter Club logo

uvasoftwaretesting15's People

Contributors

jovanovski avatar mwijngaard avatar sklencar avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

uvasoftwaretesting15's Issues

Lab 1 assessment

Good work on lab 1! The three people who were working on it, get a ++ because of the bonus assignment. (Plus-pluses compensate for possible future minuses and also get you to a higher grade because all plusses do not yield a ten yet).

Some comments:

sumDigits [] = 0
sumDigits (x : xs) = x + sumDigits xs

This works fine, but conceptually what you do is you keep using a plus to go through the list until there's nothing left and then you get a zero. This looks suspiciously like induction and can therefore be represented as a folding higher order function: sumDigits = foldr (+) 0 (also η-reduced). Similarly, your sumOfIntsInList is also foldr ((+) . sumDigits . toRevDigits) 0.

The CSI and Euler code uses lots of parenthesis, you don't need most of them. There is also some inconsistency in using backticks: in some cases you seem to be aware of them (when you use elem as infix) and in other cases not — otherwise you'd know a better way to write (\b -> (says b a)) and \ y -> y >= x.

There is a library concatenation function called concat which you can use instead of foldr (++) [] (as it turns out, even Haskell programmers need to concatenate lists all the time). There is also a notElem thing that is the opposite of elem (and you mostly use the neg anyway). Checking a list for being empty is also a library function called null (so, null xs is the same as xs == []).

Keep up the good work! Close the issue when you have no more questions.

Labs 5-6 assessment

Week 5: nicely done, but why the sudden absolute lack of any kind of comments? Usually you were not that curt. I’m especially interested in Ex.2, since it involved a judgement call: what do you think of the result of the refactoring? Did it “improve the design of existing code”? Could you test the properties described in the assignment (extensibility, efficiency, etc)? How?

Week 6: you still use weird constructions like do r <- testFermat k xs; return r. Don’t give names to pets you do not intend to keep! Just do testFermat k xs.

Week 6: too bad the bonus doesn’t work with strings, that’s the kind of messages I usually send. Besides that, a nice framework, was very easy to test.

Week 5 is (bonus: yes; test reports: no), week 6 is ++.

Lab 3 assessment

  • entails and equiv are correct, but could have been done easier by using formula constructors (Impl and Equiv, resp.)
  • parseTests is not really automated. In practice parsers are usually tested by round-tripping: given a correctly formed term, unparsing it (in this case, with show) and parsing the result should yield the same term.
  • The truth table based conversion to CNF could have worked if you had done flattening, otherwise you have awkward constructions that are impossible to describe in natural language or write down as mathematical formulae (conjunctions and disjunctions with one clause). Would not be acceptable at the exam, but here you have a bonus to nicely compensate for that.
  • Week 3 is a ➕.

Lab 4 assessment

4.1 Is ro(/0) = {/0} or {/0, {/0}}, and is there a difference between

Took me some time to figure out your notation. First of all, ρ (the Greek letter) is different from ℘ (the Weierstrass p). Second, ρ is called “rho”, not “ro”.

Anyway, ℘(∅) is a power set of an empty set. Per definition it is a set, and each element of that set is a subset of ∅. Since ∅ is the smallest possible set, there is nothing beside ∅ that would be its subset. Hence, ℘(∅) is a set with the only element, ∅. Or, ℘(∅)={∅}.

Your implementation of generateSet piggybacks on the entire QuickCheck. In other words, you do not have two solutions that were asked for.

The use of let in ex.8 is not really necessary.

Time taken 6h - this was too much time for a bonus exercise to be fun…

Now you know why testing parsers/grammars is hard. Don’t worry, it will get harder for Software Evolution ;)

Week 4 is a ➕➕

Lab 2 assessment

  • Similarly to Lab #1, your tableConvert could be a foldr with a function that you either define separately or in place as (\ x -> (++) (show ((ord x) - 55))).
  • In the same IBAN exercise you have some awkward constructs like if isAlphaNum x then checkAN xs else False. This is just conjunction, right? Write it as such! isAlphaNum x && checkAN xs is so much easier to read.
  • Similarly, all other if bla then True else False is just the same as bla.
  • In your triangle solution, you sort the poor triple all the time and then take its elements. Hopefully the compiler understands what's going on and caches it for you, but you're still stuck looking at ugly code. Use where or let clauses to define something like [a b c] = sort [x, y, z] and use the new variables.
  • Bonus didn't work for me right away (who’s fact'?) but I managed. ++ for you for the second week!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.