TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Jatin Kumar
NA
1
0
doubt in c# basic
Jun 17 2009 9:07 AM
class s
{
static void Main()
{
string d="Hello";
string e=string.Copy(d);
Console.WriteLine(d==e);
Console.WriteLine((object)d==(object)e);
}
}
o/p:
True
False
BUT
class s
{
static void Main()
{
object a = "hello";
object b = "hello";
Console.WriteLine(a==b);
}
}
o/p:
True.
In the previous case when the result of the comparison is false, we compare two strings and as string is a predefined reference type...so d result should evaluate to true and not false.
Please clear my doubt.
Reply
Answers (
1
)
dyanmic crystal report
creating crystal report by passing multiple parameter in store