468,110 Members | 1,553 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,110 developers. It's quick & easy.

Some c# interview questions

I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them

1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...

2. What are function pointers?

3. What are JOINS?

Ok.... Operartor Overloading is easy... and i can make it through
elementary concepts of Operating
System....

Can anyone explain briefly what are these things and refer to some
clearly written and simple links
where I can learn them....... and get my interview done welll.......
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?

Apr 19 '07 #1
10 1954
Hi here,

1 is parameter passing.
2 is the delegates, depend on .NET 1.0, 1.1,2.0,3.0, or 3.5. You give a
little different ans.
The conurrency is threading, I guess
hmm, you better learn some C++ concept for this developer job interview.

--
cheers,
RL
"weird0" <am********@gmail.comwrote in message
news:11**********************@p77g2000hsh.googlegr oups.com...
I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them

1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...

2. What are function pointers?

3. What are JOINS?

Ok.... Operartor Overloading is easy... and i can make it through
elementary concepts of Operating
System....

Can anyone explain briefly what are these things and refer to some
clearly written and simple links
where I can learn them....... and get my interview done welll.......
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?

Apr 19 '07 #2
My answer would be "The garbage collector and the compiler in the framework
does all that work for me so I can pay more attention to writing secure code
more efficiently so I can assist my colleagues to deploy our projects
faster, more reliably and at less expense. Am I hired?"
"Egghead" <robertlo@NO_SHAW.CAwrote in message
news:u4**************@TK2MSFTNGP05.phx.gbl...
Hi here,

1 is parameter passing.
2 is the delegates, depend on .NET 1.0, 1.1,2.0,3.0, or 3.5. You give a
little different ans.
The conurrency is threading, I guess
hmm, you better learn some C++ concept for this developer job interview.

--
cheers,
RL
"weird0" <am********@gmail.comwrote in message
news:11**********************@p77g2000hsh.googlegr oups.com...
>I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them

1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...

2. What are function pointers?

3. What are JOINS?

Ok.... Operartor Overloading is easy... and i can make it through
elementary concepts of Operating
System....

Can anyone explain briefly what are these things and refer to some
clearly written and simple links
where I can learn them....... and get my interview done welll.......
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?


Apr 19 '07 #3
YOU'RE FIRED!!!

--
cheers,
RL
"clintonG" <no****@nowhere.comwrote in message
news:%2****************@TK2MSFTNGP02.phx.gbl...
My answer would be "The garbage collector and the compiler in the
framework does all that work for me so I can pay more attention to writing
secure code more efficiently so I can assist my colleagues to deploy our
projects faster, more reliably and at less expense. Am I hired?"
"Egghead" <robertlo@NO_SHAW.CAwrote in message
news:u4**************@TK2MSFTNGP05.phx.gbl...
>Hi here,

1 is parameter passing.
2 is the delegates, depend on .NET 1.0, 1.1,2.0,3.0, or 3.5. You give a
little different ans.
The conurrency is threading, I guess
hmm, you better learn some C++ concept for this developer job interview.

--
cheers,
RL
"weird0" <am********@gmail.comwrote in message
news:11**********************@p77g2000hsh.googleg roups.com...
>>I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them

1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...

2. What are function pointers?

3. What are JOINS?

Ok.... Operartor Overloading is easy... and i can make it through
elementary concepts of Operating
System....

Can anyone explain briefly what are these things and refer to some
clearly written and simple links
where I can learn them....... and get my interview done welll.......
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?



Apr 19 '07 #4
Look,
Who's the boss?
Regards
Amir Diwan

Apr 19 '07 #5

"weird0" <am********@gmail.comskrev i en meddelelse
news:11**********************@p77g2000hsh.googlegr oups.com...
I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them
[snip]
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?
The Little Book of Semaphores -Second Edition,
availible as pdf ( code examples in the book is in Python/C, but somewhat
easily understandable ) here :
http://greenteapress.com/semaphores/

Threading in C# including Semaphores :
http://www.albahari.com/threading/index.html
http://www.albahari.com/threading/part2.html#_Semaphore

Common problems in concurrent programming :
http://en.wikipedia.org/wiki/Dining_...ophers_problem
http://en.wikipedia.org/wiki/Sleeping_barber_problem
http://en.wikipedia.org/wiki/Rendezvous_problem
http://en.wikipedia.org/wiki/Produce...sumers_problem
amongst others.

Best regards
Michael Weber
Apr 19 '07 #6
1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...
A reference is similar to a pointer, but not the same. A pointer is a
variable that contains the physical memory address of some data. It is a
number, and you can perform mathematical operations on the variable to make
it point to different memory locations. for example, if you have a pointer
to a byte, and add 1 to it, it points to the next physical byte in machine
memory. A reference, on the other hand, is a managed, object-oriented,
type-safe kind of "pointer" which "points" to the location of a class
instance, but can not be changed. It will always point to the class it is
assigned to.
2. What are function pointers?
A function pointer is a pointer that contains the memory address of a
function definition. By invoking the pointer, you invoke the function.
3. What are JOINS?
This is not a C# question (unless you're talking about LINQ, which I doubt
in this case), but a SQL question. A JOIN is a query that fetches results
from a combination of 2 or more database tables into a single tabular set of
results. In LINQ it is much the same, but applied more broadly to any
aggregate type, not confined to database tables.

--
HTH,

Kevin Spencer
Microsoft MVP

Printing Components, Email Components,
FTP Client Classes, Enhanced Data Controls, much more.
DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net
"weird0" <am********@gmail.comwrote in message
news:11**********************@p77g2000hsh.googlegr oups.com...
I heard of two c# interview questions that i still clearly don't know
and havent understood the concept. One reason is also that I havent
worked upon them

1. What is the difference between a reference and a pointer?
Allah.... I don't even know what a reference is...

2. What are function pointers?

3. What are JOINS?

Ok.... Operartor Overloading is easy... and i can make it through
elementary concepts of Operating
System....

Can anyone explain briefly what are these things and refer to some
clearly written and simple links
where I can learn them....... and get my interview done welll.......
One thing more.... there is something what we do to obtain
concurrency..... I studied that in O.S....
Semaphores...... to prevent collisions and deadlock ...... I guess...
Does anyone know what is that ? And refer me some good link to study
this?

Apr 20 '07 #7
Thanks a lot for the reply...
Kevin

Why do I need a function pointer anyway?
Like you said, by invoking the pointer you invoke the function. Why
not just call the function directly?
Apr 21 '07 #8
weird0 <am********@gmail.comwrote:
Thanks a lot for the reply...
Kevin

Why do I need a function pointer anyway?
Like you said, by invoking the pointer you invoke the function. Why
not just call the function directly?
If the bit doing the calling knows which function to call, there's no
advantage - but the point of a function pointer is that you can pass
that function pointer to something else (e.g. adding an event handler).

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
If replying to the group, please do not mail me too
Apr 21 '07 #9
Semaphores can simply be understood as a boolean flag that indicates
whether an OS resource like a thread is available or not. It is a
synchronization mechanism that is commonly used in what is called race
conditions. A race condition is when a data is shared by two threads
simultaneously, modifying which, indiscriminately, can cause wrong data
to be used bye each thread.
It is a low level functionality that probably only serves theoretical
value today as modern runtimes provide for their own multithreading
libraries and synchronization mechanisms like monitors and locks.

with regards,
J.V.Ravichandran
- http://www.geocities.com/
jvravichandran
- Or, just search on "J.V.Ravichandran"
at http://www.Google.com

*** Sent via Developersdex http://www.developersdex.com ***
Apr 23 '07 #10
Ravichandran J.V. <jv************@yahoo.comwrote:
Semaphores can simply be understood as a boolean flag that indicates
whether an OS resource like a thread is available or not. It is a
synchronization mechanism that is commonly used in what is called race
conditions. A race condition is when a data is shared by two threads
simultaneously, modifying which, indiscriminately, can cause wrong data
to be used bye each thread.
That's more like a mutex or monitor. A semaphore is designed to be more
intelligent than that - it's not that there's one resource, either
available or unavailable; it allows for you to have many instances of
the same resource, and they can be used unless there are none left, at
which point you need to wait for some to be released.

See http://en.wikipedia.org/wiki/Semapho...programming%29 for more
information.

What you've described (a simple boolean flag) is a special case called
a *binary semaphore*.

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
If replying to the group, please do not mail me too
Apr 23 '07 #11

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Jobs | last post: by
reply views Thread by softwareengineer2006 | last post: by
reply views Thread by Free PDF | last post: by
reply views Thread by ramu | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.