Skip to content

Instantly share code, notes, and snippets.

Alberto Zaccagni lazywithclass

Block or report user

Report or block lazywithclass

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:f3f994bdae98e0abf175d17ef19bce4a
### ctags
### global
lazywithclass / exercises.scm
Last active Oct 27, 2017
Exercises after The Little Schemer chapter 2 (2)
View exercises.scm
;; in the previous solution we implemented 2nd and last
;; but we did not define proper return values for the edge cases,
;; this time we will
;; your task will be to provide those values, as you can imagine
;; (sum 4 'gatto) does not have an answer
;; make it so that expressions will return true
;; a suggestion would be to paste the definitions of 2nd and last
;; above the exercises and fix the errors you get, by returning proper values
lazywithclass / exercises.scm
Last active Oct 23, 2017
Exercises after The Little Schemer chapter 2
View exercises.scm
;; write the function "2nd" that given a list of atoms
;; returns the second atom
;; return values for illegal cases are up to you
;; try to be reasonable though
(define 2nd
(lambda (lat)
;; ...
;; then write the results for these applications by running your function
(2nd '()) ;; ???
lazywithclass /
Last active Oct 22, 2017
[Teaching programming] Lesson two

[Teaching programming] Lesson two - lazyblog

From the previous lesson

It wasn't clear, and still isn't to me as of now, how S-exps are counted in a list, for example

;; how many are here? Is it 2?
(((a b c) d))
lazywithclass / exercises.scm
Last active Oct 16, 2017
Exercises after The Little Schemer chapter 1
View exercises.scm
;; given leq? that checks for lists equality
;; complete the following, so that the result is true
;; all these exercises can be solved with combinations of
;; car, cdr, cons
;; be creative!
;; this is just an example I solved for you :)
;; l -> (1 2 3)
;; m -> (0 1 2 3)
lazywithclass /
Created Oct 10, 2017
[Teaching programming] Lesson one

[Teaching programming] Lesson one - lazyblog

I hate to use "teaching" and "lesson", but those are the easiest words that come to mind right now.

I will be teaching a friend of mine how to program, from zero to (hopefully) web dev so she can see if it could be something she would like to do for a living.

The book

To give her the basic concepts I am going to use The Little Schemer. I feel like it's


161 - lazyblog

The end of 7 long months

It started in March 2017 and it ended this afternoon 19/09/2017, when I finally realised I am going to sign with this company.

The numbers


1) Write an algorithm (choose the language you prefer) that given a character string, for instance {‘c’,’a’,’i’,’o’,’p’,’a’}, will print out the list of characters appearing at least 2 times. In this specific example, it would return {‘a’}. Afterwards, comment out the cost in terms of space and time.

// I've left out validation to concentrate on the algorithm itself, I hope it's ok

// O(n) time
lazywithclass /
Last active Jul 26, 2017
Learning Vue.js

Learning Vue.js - lazyblog

A lot of time has passed since I willingly wanted to learn a frontend JS framework, I am doing it again because

  • Vue's docs seems to be detailed enough
  • there's a nice and easy way to start
  • I've used it for a take home assignment as part of a job interview and loved how it all came together easily and almost painless
  • enriches HTML the Angular.js way, so that's something I already know
lazywithclass /
Last active Jul 30, 2018
On tests, take home problems, and a HackerRank bookmarklet

On tests, take home problems, and a HackerRank bookmarklet - lazyblog

So recently I've been interviewing and as you can imagine that means doing take home problems and online tests.

I am not pointing fingers (so please continue hiring me lol), I am addressing the problem in the industry, because almost everyone is doing it in the same way, so you could say no one is directly responsible. Even though willingness to have a better process should be a thing.

You can’t perform that action at this time.