Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is the value of b
if a=5;
b=++a + ++a

Answer Posted / sandeep

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int a=5,b;
if(a==5)
{
b=++a + ++a;
Console.WriteLine(b);
Console.ReadLine();
}
}
}
}

answer is 13

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

where are auto variables stored? What are the characteristics of an auto variable?

1107


What are control structures? What are the different types?

1145


What does the c preprocessor do?

1160


What is difference between class and structure?

1160


What is ## preprocessor operator in c?

1133


any limit on the number of functions that might be present in a C program a) max 35 functions b) max 50 functions c) no limit d) none of the above

1104


What is pragma in c?

1284


Explain how can I avoid the abort, retry, fail messages?

1105


What is the difference between the local variable and global variable in c?

1015


Write a program to print “hello world” without using semicolon?

1185


What is 1f in c?

2730


What are the different properties of variable number of arguments?

1204


What is int main () in c?

1128


Explain how do you override a defined macro?

1136


Can we access array using pointer in c language?

1129