Subject: RE: [hackers-il] Teaching the Technion

From: Arik Baratz <[email-masked]>
Date: Mon, 10 Dec 2001 18:49:55 +0200

Well, I think the Technion is great. When I studied there in '94...

Seriously, now, I have not encountered much of what you are talking about. I
have a C.S. B.A., and very few of my grades do I consider 'Unfair'.

Let's tackle what you're saying one it at a time:

> However, as eventually became aware of, many people in the industry don't
> care about what I know as much as they care about my diploma. And the

True to some extent. Fact is, I'd hate to work in a place which would
appreciate diplomas over talents, so I don't care about those people
anyways.

> diploma does not motivate me much, because I know that it is more a test
> of how much abuse the graduate is willing to take, rather than an
> indication of his knowledge and proficiency.

Ahem. I didn't feel that when I went there. Maybe EE and CS is different.
There is abuse. It is worse for undergrads. I usually shrugged it away with
a smile. It can't be that bad.

> C-Shell in the advanced programming course of both the EE and CS
> faculties. I discovered a university that teaches compilation and data
> structures and algorithms with computer exercises in C, despite the fact
> that Perl (or Python or Ruby - let's not start a language war here) is
> much more suitable. (in the CS' faculty's "Computer Graphics" course they
> write C programs to generate VRML code - %-)) I saw courses where the

Who f***ing cares which language you use? So what if language X is perfect
for course Y. Hey, my AI course teacher made us study LISP. A language is a
language is a language. They're all Turing-complete.

Stop bothering yourself with minuscules and look at the bigger picture. And
the bigger picture is that you get the concept of an interpreted language
while you learn C-Shell, you learn data structures because you're supposed
to learn some concepts of data structures and not to polish your C skills.
Well, I admit that using C for VRML is pretty lame, but it doesn't offset my
argument: concentrate on computer graphics and NOT on the language. The end
and not the means.

> As a result of all this, I became more frustrated and less eager to take
> any more of this as time went by. Like I said, I decided to take the path
> of least obstacles, simply because this is the path in which I have the
> biggest chance of being rewarded.

What, you became frustrated because they wouldn't let you use Perl in data
structure course? I heard there's some good medical treatment for this. Try
looking for an SSRI brand. Make sure you understand the side effects...

On a more serious note, there are some on the staff that simply don't care.
Period. Can't be helped. Most of them, per my experience, do tend to have
some concept of the course they're teaching, of the material taught and the
level of exam expected. If you go to a university, you're bound to come
across a few.

Your savior is the teaching assistant. Young, more energetic and easier to
handle, they can do wonders for the course and for you. And if they need a
nudge in the right direction here and there - help yourself. Don't be shy.
Go to their room, knowing that you have a right to get what you need, be it
some more assistance or a reevaluation of the test. And there are many
courses with more than one teacher, and more than one T.A. so you don't
usually get stuck with the indifferent ones.

And if the worst happens, and there's one lecturer, one T.A., both are bad,
lazy, rude and beyond redemption - seek for the extreme alternatives -
unsubscribe from the course, take it next year, take a parallel from another
faculty, go to the dean. I never went to the dean, I took a course a
semester after only once.

> studied in it..." And people just think that an engineer is defined as
> someone who has a first degree. (I don't)

Uh, actually, it does.

> are pretty good. I don't expect to be a perfect "A" student. But I want
> justice, and I don't seem to get it.

You're right. Some grades don't reflect your knowledge and skill. So? You
can look at it two ways: You can be a perfectionist, and redo it just to
prove the point, and you can realize that just like in real life, the other
guys can only appreciate you based on what you say, do, write, etc. And
sometimes it's not at par with what you think is fair. That's life.

> I wish I could have stayed in the Technion and try to change it from
> within. But I don't have time to finish a second degree, get a Ph.D.
> become an associate professor, become a professor, and then hope I become
> the dean of the EE or CS faculties. And even then, I don't know how much I
> can do.

The Technion (and every university, institution and working place) is full
with politics, which you have to deal with if you want to change. If you
know your way through the political BS, you can change it as a student. If
you don't, you probably won't become a professor.

> Maybe I should take the Moed Beith or take the course again and try to
> improve my grade. In some courses, it would be useless, at least in EE.
> And in any case it contradicts the Path of Least Obstacles<tm>
methodology.
> And will cost me dearly in even more frustration and feelings of
> injustice.

And what a moral do we learn here. That's the greatest tradeoff in life.
You'll encounter it so many times you'll forget you came to the concept in
the Technion. Here are the rules of an open life:

* Doing things right will lead to frustration
* Doing things wrong will lead to frustration
* Demanding justice and getting it will lead to frustration
* Accepting whatever comes your way leads to frustration
* Getting rewarded for what you slaved for will lead to a temporary relief
from frustration.

See my comment about SSRI above.

-- Arik

---

From: Shlomi Fish <[email-masked]>
Date: Mon, 10 Dec 2001 23:12:15 +0200 (IST)

> have a C.S. B.A., and very few of my grades do I consider 'Unfair'.

You have no idea how much I am jealous of you. I guess the EE department
is different than the CS faculty.

> appreciate diplomas over talents, so I don't care about those people

Well said.

> a smile. It can't be that bad.

I do.

> language is a language. They're all Turing-complete.

Let's teach AI in Intercal! You know - it is Turing-complete too. You
should teach a course in a language that is suitable for this course. And
Perl is much more suitable for most courses that require computer
exercises. Muli can testify that he today wrote in Perl in 5
minutes something that would have taken him an hour to code in C. And I
can testify for many cases where I successfully used Perl as an aid in the
coursework we were given.

Teaching in C because the students learned it as a first programming
language, is like looking for a coin you lost in the darkness, in the
light of a street-light.

> argument: concentrate on computer graphics and NOT on the language. The end

C-Shell is a broken shell. Period. It should not be taught. The fact that
the Technion still uses it shows how lame and conservative it is. And the
fact that it assumes that everything can be effectively taught with C is
much more so.

> looking for an SSRI brand. Make sure you understand the side effects...

That was an annoyance, not a cause for frustration. What really made me
frustrated was the injustice I felt for being mis-graded. And as my
experience with Anat told me, sometimes I can only improve my situation by
a very small margin.

> semester after only once.

Again - I am jealous of you. Maybe the CS faculty is run much better than
EE.

> > someone who has a first degree. (I don't)

I define an engineer as somebody who performs engineering tasks,
regardless of whether he is a graduate or not. During my first work as a
programmer, my boss (a very good man whom I respect and admire) showed a
visitor around our room and said: "here we have two software engineers and
one hardware engineers.". I was one of the software engineers in question.
At that time I thought it was a funny way to put it (I still like to think
of myself as a programmer). But now I'm proud that he said that.

BTW, my boss was a Technion graduate and a laurete of "Pras Yisrae'el".

Another example: in the third place I worked in, we were informed that we
are going to hire a Q&A engineer, and that "she would be our first woman
engineer". I don't think she was a graduate either. And the founders of
the company were both Technion graduates.

Therefore, I believe you should qualify a man as an engineer based on what
he does and how well he does it, instead of based on what he did or did
not learn. That is true for other professions as well.

> sometimes it's not at par with what you think is fair. That's life.

That's not life. That's life in the EE faculty of the Technion.

> you don't, you probably won't become a professor.

If I won't become a professor just because I don't know the political BS,
then the Technion is definitely not a place to be.

> * Getting rewarded for what you slaved for will lead to a temporary relief

I totally disagree with you. I felt very happy working as a software
engineer, and felt very happy working on my open-source software, my
stories, etc. Furthermore, I felt good about myself working on my home
assignments and managing to solve them. When I passed a course on 57 or
58 when I deserved to pass it on more, I felt good knowing that I deserved
a better grade. When not in the Technion, very few things make me
frustrated.

These are the facts of my life as I have lived them. I became frustrated
when something frustrated me, not otherwise.

> To unsubscribe from this group, send an email to:
> [email-masked]
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>

----------------------------------------------------------------------
Shlomi Fish        [email-masked]
Home Page:         http://t2.technion.ac.il/~shlomif/
Home E-mail:       [email-masked]

"Let's suppose you have a table with 2^n cups..."
"Wait a second - is n a natural number?"

---

From: "Nadav Har'El" <[email-masked]>
Date: Tue, 11 Dec 2001 00:04:48 +0200

> is different than the CS faculty.

Shlomi, please don't get disparaged. Remember: people tend to look back
at things in nostalgy, remembering the good things and downplaying the
bad things.
Notice the comonality between all people (including me) that have said good
things about the Technion in this thread: It's not the department we studied
in, but rather the fact that we all finished our BA quite a few years ago (I
finished it in 1994). The BA period wasn't easy for any of us (at least not
for me), and at times I also cursed those hard tests, exercises, (a relatively
small number of) uncomprehensible teachers, thick-headed TAs, unfair tests,
unfair grades, hard and stupid exercises, and all these things. I can tell
you stories upon stories on each of those things. But after we finished all
of that, we remember more the good things we got out of our alma mater (the
Technion): the ways of thinking, methodology, basic knowledge, and even that
coveted piece of cardboard - the diploma. After several years we can also
appreciate more what we got out of the Technion. I *know* that I don't apply
in my current career at least 90% of the material I learned in my BA (after
all, topology and banach spaces aren't very applicable to programming) -
but I still think that my time was well-spent, and even if nothing more,
the 3 years of BA studies were an excellent excercise of my mind - something
that I badly missed in school.

I really doubt the EE department sucks more than the CS (or any other)
department. But I admit don't have much personal experience with that
department, other than taking two courses there ("digital systems", and
"quantum computation"), going to a few colloquia (quite interesting), and
talking to a few processors over there (which seemed very nice) about perhaps
doing a doctorate in EE.

> the Technion still uses it shows how lame and conservative it is. And the

You know I agree with you there...
There's simply no excuse for continuing to teach C shell, and using "we
don't want to rewrite all the exercises" as an excuse is even worse (because
teachers should not be making excuses to avoid working hard, just like
you wouldn't want that from any other profession).

> > handle, they can do wonders for the course and for you. And if they need a

Here I disagree. In most of the courses I took, especially when large classes
were involved (e.g., in the physics and CS department), the teachers were
fairer and more willing to listen than the TAs. The TAs were usually the ones
to grade exercises and tests, and often did it very arbitrarily and unfairly.
For example, in one CS course I got a 79 (graded by some TA), and after
appealing, my grade was changed to 98 (graded by the teacher). In another
course (again, in CS), the TAs kept giving me scores around 60 on my
exercises, which I considered to be correct. So I decided, "the hell with them,
I know this subject well, and the exercises are just a magen score", and when
I took the test I got a very high grade (I guess they had to be less arbitrary
when grading those).

Of course, I've also had many great TAs, so you can't make any generalization -
these guys are human like the rest of us, and most of them don't have much
teaching experience.

> I define an engineer as somebody who performs engineering tasks,

Shlomi, it is nowadays common to define an engineer someone who has an
"engineering degree". Just like you can't go around calling yourself an
"architect" just because "look, I designed my own house, and it turned out
very nice! wow, I think I'm a good architect!". Just like you can't call
yourself a "psychologist" just because you feel that you are good talking to
people and know a lot of psychology from all the books you've read.

You can call yourself a software "engineer" informally, just like you can
even call yourself a software "architect", but you better not put that down
on your resume before you have a BA, because people might find it deceptive.

If you find it silly - well, it is. Just like it's silly to call people
Dr. Somebody, or that even if you're really smart you shouldn't call yourself
"Dr." if you haven't formally completed a doctorate. These are just some
of societies conventions, which may be archaic but are still conventions.

> of myself as a programmer). But now I'm proud that he said that.

Well, you should be :)

> not learn. That is true for other professions as well.

Maybe you *should*, but it's not what people commonly accept with you hear
that word...

> That's not life. That's life in the EE faculty of the Technion.

Isn't anybody else on this list from the EE department, and can stand up
for its lost dignity ? ;)

> then the Technion is definitely not a place to be.

Right. Politics can help you get ahead more quickly, or to step over people
even if they are somewhat better than you - but if you're a brilliant
researcher, you'll be noticed even if you suck at politics.

-- 
Nadav Har'El                        |      Monday, Dec 10 2001, 26 Kislev 5762
[email-masked]             |-----------------------------------------
Phone: +972-53-245868, ICQ 13349191 |If glory comes after death, I'm not in a
http://nadav.harel.org.il           |hurry. (Latin proverb)

---

From: mulix <[email-masked]>
Date: Tue, 11 Dec 2001 00:25:10 +0200 (IST)

> coursework we were given.

yes, yes.
in 'introduction to operating systems' today, the lecturer showed
how useful the unix pipe line is by demonstarating the follwoing
command:

cat infile | tr ' ' '\n' | tr '[A-Z]' '[a-z]' | sort | uniq -c

he then asked us how long it would take to write something like this in
c. he estimated it in at least an hour of work.

so, i whipped out the trusty laptop (actually, it was already on my
lap at this stage since i was going over some syscalltrack code) and
wrote it. but - it's pretty obvious that to do the task efficiently, you
need a hash table and c doesn't have one. so i cheated and used
perl, which does have hashes (maps) built in.

so i came up with this little scriptlet:

#!/usr/bin/perl -w

use strict;

my %hash;
my $word;
while (<>) {
  chomp;
  my @words = split(/ /);
  foreach $word (@words) {
    $hash{$word}++;
  }
}
foreach $word (keys %hash) {
  print "$hash{$word} $word\n";
}

total time to write? about a slide and a half, 7 minutes. so i gently
raised my hand and told the instructor i wrote it. just as his look of
stunned surprise was turning into disbelief, i said "of course, i
cheated and used perl", whereupon he relaxed, smiled and said "ah, but
anything you can do in the shell, you can do twice as fast in perl".

moral of the story?

0. who said there's a moral?

1. always have your laptop ready and able to code. you never know when
it might come in handy [this is not the first lecture where i whip it
out in class just to do something somone claimed cannot be done or
cannot be done quickly].

2. use the right tool for the right job. perl suited the purpose, so i
used perl. this does most emphatically *not* mean perl is better than
c. if he would have shown a miniscule kernel in c++ and said it
would take at least a couple of months to write it in c, you can guess
what i would be doing right now instead of composing an email - and
doing it in c, not in perl. say, shlomi, wasn't there a project to build
a perl os, or at least a perl shell?

thank you for listening, it's been a pleasure,
-- 
mulix

http://www.pointer.co.il/~mulix/
http://syscalltrack.sf.net/

---

From: Alon Altman <[email-masked]>
Date: Tue, 11 Dec 2001 03:49:51 +0200 (IST)

>   print "$hash{$word} $word\n";

Hmm... you're doing it case-sensitvely... you forgot the tr///... :)

> a perl os, or at least a perl shell?

Actually, the mini-shell in some distros' installers is written in perl.

  Alon

-- 
This message was sent by Alon Altman ([email-masked]) ICQ:1366540
The RIGHT way to contact me is by e-mail. I am otherwise nonexistent :)
--------------------------------------------------------------------------
Philosophy will clip an angel's wings.
		-- John Keats

---

From: "Nadav Har'El" <[email-masked]>
Date: Tue, 11 Dec 2001 08:49:30 +0200

On Tue, Dec 11, 2001, mulix wrote about "Re: [hackers-il] RE: Teaching the Technion":
> ... 
> ...
> ...

I'd say the exact opposite: anything you can do in the shell naturally, do
it because it will take you twice as long to do it in perl. Note the
emphasis on *naturally* - there are some stuff the shell simply wasn't made
to do. This is why you see a lot of awk use, even by diehard shell-scripters.

It would take me about 20 seconds (and I'm not exaggerating) to write the
shell pipeline above. 7 minutes is a lot, unless this is some script you'll
save and reuse...

> used perl. this does most emphatically *not* mean perl is better than

Perl is better than C in this case, but shell (and the standard Unix
filters) are even better.

P.S. you can make the shell pipeline even shorter - there is no need
for two sepearate tr calls, and certainly not for a cat call...
	tr '[A-Z] ' '[a-z]\n' <infile | sort | uniq -c

-- 
Nadav Har'El                        |     Tuesday, Dec 11 2001, 26 Kislev 5762
[email-masked]             |-----------------------------------------
Phone: +972-53-245868, ICQ 13349191 |Today is the tomorrow you worried about
http://nadav.harel.org.il           |yesterday, and now you know why.

---

From: Shlomi Fish <[email-masked]>
Date: Tue, 11 Dec 2001 10:50:40 +0200 (IST)

On Tue, 11 Dec 2001, Nadav Har'El wrote:

> very nice! wow, I think I'm a good architect!".

common != right. I don't care what other people think. (Feynman, who was
an Engineer for a brief time, had a book with a very similar title) I do
not structure my cognition according to the whims or conventions of
society. (IMO, it is very dangerous to do so.) I structure it according to
what I deduced that it is right.

The only rules I follow are the rules of logic and of objective ethics
that is derived by that. I'll go on referring to people who do not have a
Bachelor degree as engineers, regardless what the society (or the
shallow-thinking part of it) thinks of it.

> Just like you can't call

I'm not sure if I can call myself that. But other people, whom I helped,
can call me a psychologist or a counseler, or whatever.

> on your resume before you have a BA, because people might find it deceptive.

I'm not saying "Shlomi Fish - Software Engineer" on my resume. I'm just
saying "Shlomi Fish". Then I say "programming", "creative writing"
"mathemetics", etc. Check out my resume at:

http://www.google.com/search?q=cache:fKV2YFu5sPk:t2.technion.ac.il/~shlomif/SFresume.html+shlomi+fish+resume&hl=en

(sorry - the t2 homepages are temporarily down from some reason)

If I had said something like that it would be "Shlomi Fish - Programmer,
Writer, Amateur Mathematician, Wannabe Philosopher and someone who studies
in the Technion in the vain hope of becoming an Electrical Engineer". :-)

> of societies conventions, which may be archaic but are still conventions.

I don't call somebody Dr. if he does not have a Doctorate. That's because
Dr. means just that. However, I am willing to call someone a phisician
(just for example) even if he doesn't have an M.D.

> Maybe you *should*, but it's not what people commonly accept with you hear

I accept this fact. But many words have alternate meanings, and some words
are completely contorted. I use only the correct meaning of the word.

Regards,

	Shlomi Fish

---

From: Shlomi Fish <[email-masked]>
Date: Tue, 11 Dec 2001 11:16:53 +0200 (IST)

> at things in nostalgy, remembering the good things and downplaying the

It's not that I am unhappy now. I'm just frustrated with the whole
Technion way of doing things. And I'm always going to remember that. I
know I was happy in high school, but I know some of the subjects I had to
study had annoying tests, which I could not never hope to pass on a good
grade. (at least not without writing a lot of non-sense in the test, which is
something I neither can or wish to do.) But in some ways, even high school
was more fair than the Technion because you the Teacher knew you very
well, and usually had time to hear your complaints.

> coveted piece of cardboard - the diploma.

What bothers me the most now is that is that the Technion causes me
frustration. And I don't think I improved my way of thinking, methodology,
etc. because of it. I'm not going to be grateful for the Technion for
giving me a diploma, because at the moment the balance is tilted
towards me.

> After several years we can also

I exercise my mind on a regular basis, whether in the Technion or not. The
fact that I am sometimes not rewarded for my thinking efforts is what
bothers me.

> talking to a few processors over there (which seemed very nice) about perhaps

The professors seem very nice and usually are nice. However:

1. Many of them if they write a test that is too hard or too long, leave
it at that, and tell themselves that they will compensate it with a
factor.

2. Some of them can't tell a hard test even if it hit them in the head.

3. Some of them refuse to let students talk to them face to face.

4. Most of them care more about the statistics of the course's grades,
rather than making sure hard-working and/or talented students would be
rewarded.

Perhaps there is a similar situation in other departments. Right now I'm
bitter about my studies in general, and I induce it to the rest of the
Technion. That's life in the Technion for you.

Regards,

	Shlomi Fish

---

From: Oleg Goldshmidt <[email-masked]>
Date: 11 Dec 2001 17:21:32 +0200

> c. he estimated it in at least an hour of work.

It takes a few seconds to go to awk info pages that provide an almost
complete solution

     awk '
     {
         for (i = 1; i <= NF; i++)
             freq[$i]++
     }
     
     END {
         for (word in freq)
             printf "%s\t%d\n", tolower(word), freq[word]
     }'

-- 
Oleg Goldshmidt | [email-masked] 
"If it ain't broken, it has not got enough features yet."

---

From: Oleg Goldshmidt <[email-masked]>
Date: 11 Dec 2001 18:03:13 +0200

>              printf "%s\t%d\n", tolower(word), freq[word]

It takes a few more seconds (after the message is posted, of course)
to realize that tolower should be applied when incrementing freq[],
i.e

              freq[tolower($i)]++

and not in printf. Actually, it will be more efficient to run
tolower($0) on each line of input.

Of course, it would take me a couple of minutes to write the thing - I
actually spent about a minute and a half devising the algorithms above
in my head (pretty standard in awk). Then I simply remembered that it
was in the info (it does take a few years of RTFM to know the info
pages almost by heart), and it took a few seconds from there... Proves
nothing. Given a verbal description of the problem I would probably
resort to awk or shell with almost equal probability. I would not
think of perl (though I realize it is suitable) or C/C++ (though I
agree with Omer's comment regarding generic programming).

Now, this is not the whole story. I forgot (yes, forgot) to
sort. Trust me (or check), I just forgot to paste a line from
another place in the same info page. The END stanza should read

     END {
         sort = "sort"
         for (word in freq)
             printf "%s\t%d\n", word, freq[word] | sort
         close(sort)
     }

The sorting is a bit of cheating, btw, since it uses the system
facility - awk does not have a built-in sort function AFAIK. However,
I do think it's allowed. Mulix, does your perl script sort? It looks
very similar to the original awk above - no tolower(), no sort. Omer's
code uses STL's set which is sorted.

Well, with thinking of what actually to cut'n'paste it is more than
a few seconds, but still under a minute net time expense... All in all
10 minutes wasted writing two hackers-il postings... Oh, shuck - it's
fun.

---

From: mulix <[email-masked]>
Date: Tue, 11 Dec 2001 18:31:19 +0200 (IST)

> code uses STL's set which is sorted.

no, it didnt sort (or do tolower()) in the version i posted. adding
those are left as an excersize to the reader.

here's a python scripltlet which does sort and do tolower().

#! /usr/bin/env python

import sys

def process(f):
    dict = {};
    for line in f.xreadlines():
        for uc_word in line.split():
            word = uc_word.lower();
            if (not dict.has_key(word)):
                dict[word] = 0;
            dict[word] += 1;
    keys = dict.keys();
    keys.sort();
    for word in keys:
        print '%4d %s' % (dict[word], word);

if __name__ == "__main__":
    process(sys.stdin);

> 10 minutes wasted writing two hackers-il postings... Oh, shuck - it's

indeed. time for an intercal refresher course, i wander?

/me wonders who will be the first to pick up the glove and post a c
version.
-- 
mulix

---

From: "Nadav Har'El" <[email-masked]>
Date: Tue, 11 Dec 2001 20:38:54 +0200

> facility - awk does not have a built-in sort function AFAIK. However,

No, it doesn't. It suprised me the first time I noticed it too. I ended
up writing a bubble-sort function in awk :) (I didn't have the patience
to write a better algorithm, and it was a short array anyway)

-- 
Nadav Har'El                        |     Tuesday, Dec 11 2001, 27 Kislev 5762
[email-masked]             |-----------------------------------------
Phone: +972-53-245868, ICQ 13349191 |Learn from mistakes of others; you won't
http://nadav.harel.org.il           |live long enough to make them all yourself

---

From: Oleg Goldshmidt <[email-masked]>
Date: 05 Sep 2002 00:33:04 +0300

"Nadav Har'El" <[email-masked]> writes:

> On Tue, Dec 11, 2001, Oleg Goldshmidt wrote:
>
> up writing a bubble-sort function in awk :) 

Sorry for returning to an old (and hopefully dead) thread - on a
tangential issue at that. I just found out that the newer gawk (3.1)
has asort() that sorts arrays. Very useful. Check out the info.

-- 
Oleg Goldshmidt | [email-masked] 
=================================================================
"... Of theoretical physics and programming, programming embodied 
the greater intellectual challenge." [E.W.Dijkstra, 1930 - 2002.]