Thursday, June 28, 2007

Wednesday, June 27, 2007

some more interview questions

1. Consider a linked list where every node has one data field and one next field. The next field is used to point to the following node. You get a pointer to a node in such a list. You are required to delete the node. Please describe how you delete such a node. You are not allowed to change the structure of the nodes.

2. Consider a linked list where every node has one data field and one next field. You need to explain what operation do you need to do in order to be able to traverse such a list from head (a pointer to the first node of the list) to tail (a pointer to the last node of the list) and from tail to head. You are not allowed to change the structure of the nodes.

3. Explain the assembler language that you're familiar with and describe the architecture of the processor this assembler is for.

4. Write a Lex program that copies a file, replacing each non-empty sequence of white space by a single blank

5. Write a Lex program that copies a C program, replacing each instance of the keyword float by double

6. Consider the following C code:

int state;
int **transition_table;/* num_states x alphabeth_size*/
.
.
.
state = transition_table[state][input_char++];
Suggest how to optimize this code.

7. Please give an object oriented description of the data structures required for an implementation of a jigsaw-puzzle game.

8. implement int strcmp(const char *s1, const char *s2); and int strncmp(const char *s1, const char *s2, size_t n); in the assembler language that you are familiar with.

9. Write a grammar (e.g., for YACC) for a calculator that supports the four basic arithmetic operations:
-+*/ and using the round brackets ( and ) for priorities.

10. Write a function void fizz_bazz(char* in, char* out, int l, int skew) that receives two strings, an input string and an output string. The memory for both strings is allocated a-priori and the length of both strings is l. You need to implement the function so that the output string will be as follows:
* every character c in the string in should be shifted skew positions upper or further.
* whenever a character in an odd position in the in array is being processed print fizz
* whenever a character in an even position in the in array is being processed print bazz
* whenever a character in a position that is divisible by 3 in the in array is being processed print boo

so for the following contents in the in array
ABxyz
the expected contents in the out array is
NOklm
and the output on the standard output is expected to be
bazzboofizzbazzfizzboobazz

Tuesday, June 26, 2007

Summer!

The kids playing in a small pool last weekend.


Don't waste your time reading EULA

In the coding horror blog (see:http://www.codinghorror.com/blog/archives/000892.html) I read a nice explanation why it does not make sense to waste your time reading EULAs.

Funny, I had a similar discussion at work with a colleague...

Thursday, June 21, 2007

XML generation tools

Motivation:
Given an XML Schema (not a DTD) -- generate XML instances that are valid against the given schema.
This is very useful in creating tests suites, as it allows production of "positive" examples. For negative example generation, I am not familiar with any available tool other than untidy (which can only cause "not well formed" problems but also gives well formed examples by manipulating rules that give different representation to what is syntactically/semantically the same thing, such as adding/removing whitespaces).

Here is a list of available tools for this task:
* oxygen
* xml spy
* XML-XIG: XML Instance Generator (pronounced XML-ZIG)
* Stylus Studio

Anyone aware of alternative (better) tools?

Monday, June 18, 2007

untidy - XML Fuzzer -- in beta 2

Untidy, and XML fuzzer, is now available in beta 2: http://untidy.sourceforge.net/

State Of The Art -- ACLTwiki -- NLP and CL

From the abstract of the page:

``The purpose of this section of the ACL wiki is to be a repository of k-best state-of-the-art results (i.e. methods and software) for various core natural language processing tasks.
As a side effect, this should hopefully evolve into a knowledge base of standard evaluation methods and datasets for various tasks, as well as encourage more effort into reproducibility of results.
This will help newcomers to a field appreciate what has been done so far and what the main tasks are, and will help keep active researchers informed on fields other than their specific research. The next time you'd need a system for PP attachment, or wonder what is the current state of word sense disambiguation, this will be the place to visit.''

What To See -- NLP and CL readings and a useful tool

Here's the abstract of a useful page I found on the web:

``I have a routine problem that sometimes paper titles are not enough to tell me what papers to read in recent conferences, and I often do not have time to read abstracts fully. This collection of scripts is designed to help alleviate the problem. Essentially, what it will do is compare what papers you like to cite with what new papers are citing. High overlap means the paper is probably relevant to you. Sure there are counter-examples, but overall I have found it useful (eg., it has suggested papers to me that are interesting that I would otherwise have missed). Of course, you should also read through titles since that is a somewhat orthogonal source of information. Here is how to use the system. You upload your personal bibtex file and have the system compare it to a known conference index; it will then present a list of papers, sorted by relevance.''

See: http://www.cs.utah.edu/~hal/WhatToSee/

Saturday, June 16, 2007

Dragon Fly

A few pictures of Dragon Flies that I took today in עין חמד ('ein xemed):



Thursday, June 14, 2007

דוד נסים נפטר

Nissim Sarfatyהערב, נפטר דוד-אמי מצד אביה, נסים צרפתי.

דוד נסים היה אדם נפלא: פעלתן, דעתן ואופטימי, עד לכניסתו המצערת למחלקה סיעודית לפני מספר שבועות.

תמיד אזכור את הסבריו המלומדים, את הצהרותיו הבלתי מתפשרות .

הוא היה משתתף בהפגנות, כותב ומגיב באמצעי התקשורת ובפני חברי-כנסת, שרים ורשויות.

איש שיחה מרתק.

ציוני ואוהב הארץ.

אדם נפלא.

הוא יחסר לי מאד.

יהי זכרו ברוך.




A picture of mine made it to the finals in a "funniest picture" contest

A picture of mine made it to the finals in a "funniest picture" contest. Please vote for me :-)

see: http://www.tapuz.co.il/tapuzforum/main/Viewmsg.asp?forum=149&msgid=100439566

Wednesday, June 13, 2007

Interactive Digital Photomontage

You took several group images of the same group, but in none of the pictures all look well. The following technology will help to produce a new picture that contains the "good" parts from the pictures you give it. So you can, for example, create a new group picture where everyone is smiling and no one has his/her eyes closed.

COOL!

http://grail.cs.washington.edu/projects/photomontage/

Sunday, June 10, 2007

Halcyon smyrnensis in my backyard

A Halcyon smyrnensis flew into my backyard. While resting, a cat stormed on him and caught it between his gaws. After playing with it for a few minutes, the cat let go and the bird run away. The cat went to sleep, and the bird, terrified, waited (perhaps it was wounded... I don't know...). I took the chance to grab a few photos. We put a deep plate with water for the poor bird. Chased away the cat and went to bed. We hope that the bird will get over the trauma and move on before another bird takes a shot...







Saturday, June 2, 2007

ICML 2007

The 24th Annual International Conference on Machine Learning is just around the corner and will be held in conjunction with the 2007 International Conference on Inductive Logic Programming at Oregon State University in Corvallis, Oregon.

See the list of accepted papers at: http://oregonstate.edu/conferences/icml2007/paperlist.html

An interesting yet amusing view of writing job advertisements

I read an interesting and amusing post in use Perl about job advertisements

It says that you want to hire people that fit. It also says that the audience splits into the following four groups of people:
1. Those that qualify: have the necessary required skills and knowledge and that can do the job
2. Those who are unqualified and are honest about it
3. Those that think that they qualify but they don't
4. Those that do not qualify but are not honest about it and lie

This looks like a partition that should make life easy: you want to hire people from the first group and not from any other group.

Two problems are being raised:
One that those that qualify most probably already are working. This means that any advertisement targeted at them should be clear about why switching jobs is worth doing for them?
The second problem is that it is hard to filter out the people from groups 3 and 4.

The post further tries to give some advice about the proper way to advertise your "wanted ad".

I like that posting very much and enjoyed reading it.

google face search

Try adding to the query string in the resulting search URL in your google search the following: &imgtype=face

see: http://emad.fano.us/blog/?p=556

I played with this a few times now and it is kind-off disappointing... this feature has some serious maturing to do :-)

Photographing children in the kindergarten

I started a new thread about Photographing children in kindergarten.
My goad i to get tips regarding the approach, lighting, composition, technical issues and the general approach.

The discussion is in Hebrew in a Tapuz forum: http://www.tapuz.co.il/tapuzforum/main/Viewmsg.asp?forum=809&msgid=99785178

JINR -- publish your negative results on NLP and ML

JINR is an electronic journal, which brings to the fore research in Natural Language Processing and Machine Learning that uncovers interesting negative results.

They idea is that while we see a lot of publications about successful attempts, it is not clear which paths are not promising directions.

Much can be learned by analysing why some ideas, while intuitive and plausible, do not work. The importance of counter-examples for disproving conjectures is already well known.

Negative results may point to interesting and important open problems. Knowing directions that lead to dead-ends in research can help others avoid replicating paths that take them nowhere. This might accelerate progress or even break through walls!

see: http://www.jinr.org/