Skip to content

Instantly share code, notes, and snippets.

# Easily extract all compressed file types
extract () {
if [ -f $1 ] ; then
case $1 in
*.tar.bz2) tar xvjf $1 ;;
*.tar.gz) tar xvzf $1 ;;
*.bz2) bunzip2 $1 ;;
*.rar) unrar x $1 ;;
*.gz) gunzip $1 ;;
*.tar) tar xvf $1 ;;
whats the point of 'se' in this sentence? why not just: 'Él va al restaurante.'
Bisade, "se" is used because the verb is reflexive. Duolingo is technically incorrect. It should be He leaves for the restaurant--with the implied meaning that he is in one place headed for another place. IR (to go) changes meaning when used as a reflexive verb. IRSE = to leave. Think of these two English sentences: I am going to the restaurant tomorrow. I am leaving for the restaurant from my office. The first would use IR; the latter would use IRSE.
@ee7klt
ee7klt / parprog0
Created January 17, 2017 04:27
parallelism on the jvm ii
class Account(private var amount: Int = 0) {
def transfer(target:Account, n: Int) =
this.synchronized {
target.synchronized {
this.amount -= n
target.amount += n
}
}
}