Notizen
More Stuff chapter
Inhalt der Notizen (1)
Seite 1
Regex or regular expression it's one way that we can take a chars pattern (es 'abc') and compare it against random or predefined words to see if it match.
Syntax: "powerball" =~ /b/ => 5 return value it's the index of b char in the given string...another way of using regex is through the .match method :
/b/.match("powerball") be aware of the fact that is case sensitive.
Vars as pointers which means that vars actually point to a space of memory and do not hold them self the data that is assign to them...this is an important thing to remember to be able to know when the caller is mutate and when it is not....
Procs are block of code that are saved into vars so we can called them as parameters of an method and use them in our program without every time having to repeat the block.....
Exception Handling is a process that deals with errors in a predictable way....the reserved words are 'begin', 'rescue' and 'end' and give us the power to decide what to do in case some kind of possible error occurs in our program without stoping the execution of the program it self.
Informationen
- Beschreibung
- Notiz am More Stuff chapter, erstellt von Andrei Ilinca am 20/04/2016.
- Erstellt von
- Andrei Ilinca · Apr 2016
- Aktualisiert
- 21 Apr 2016
- Aufrufe
- 0
- Bewertung