Want this question answered?
yes we can run java program without using main. we can run program by declaring the variable static..
You have to declare it. The simplest way to do so is by using the Dim keyword. For example if you want a string variable called someString you would declare it thus: Dim someString as string
You declare it by this: Dim var as integer or Public var as integer You can use other types instead of integer like long, double, string, byte etc. Using Public is for making a variable accessible from everywhere and using Dim is for making it accessible only from where you declared it from. For using the variable you just type: var = 1 var = "something" var = 5 + 10 * (2 - 3) var = var & "abc" var &= "abc" In each case the variable will have these values: 1 something -15 Whatever var had before plus abc Again whatever var had before plus abc These are the basics of using a variable
the example of array over charcter variables is char ["string"]
The required c program is given below /*Swapping(interchange) the two entered numbers*/ #include<stdio.h> main() { /*Without using third variable*/ int a,b,t; printf("Enter a:"); scanf("%d",&a); printf("Enter b:"); scanf("%d",&b); a=a+b; b=a-b; a=a-b; printf("\n After swapping without using third variable"); printf("\na=%d\nb=%d",a,b); }
It usually means that a software program is installed there, or has told the system that it is not using, but WILL use this part of memory for storage.
Pointer is a variable that stores the address of another variable . So pointer basically stores the address of another variable and size of pointer can be evaluated by using sizeof operator.
One of its advantage is to save storage space.
it stores dadta in notcontiguous mode.so when we want to allocate a memory we can do it by using pointer. it stores dada in notcontiguous mode.so when we want to allocate a memory we can do it by using pointer.
Yes, but not for long term storage, only while a program is executing using its stack.
There are several ways to do this in C: // nums to swap int a = 5; int b = 10; // using a temporary variable - often the fastest method int temp; temp = a; a = b; b = temp; // using addition (no additional storage needed) a = a + b; b = a - b; a = a - b; // using xor (no additional storage needed) a = a^b; b = a^b; a = a^b; // using only one line (no additional storage needed) // note, this appears to be a compiler-dependent way to swap variables a = a + b - (b=a);
yes we can run java program without using main. we can run program by declaring the variable static..
You have to declare it. The simplest way to do so is by using the Dim keyword. For example if you want a string variable called someString you would declare it thus: Dim someString as string
i dn't know. haha
see : Write_a_shell_program_using_the_if-the-else_to_test_whether_a_variable_name_is_a_directory_or_a_file
You declare it by this: Dim var as integer or Public var as integer You can use other types instead of integer like long, double, string, byte etc. Using Public is for making a variable accessible from everywhere and using Dim is for making it accessible only from where you declared it from. For using the variable you just type: var = 1 var = "something" var = 5 + 10 * (2 - 3) var = var & "abc" var &= "abc" In each case the variable will have these values: 1 something -15 Whatever var had before plus abc Again whatever var had before plus abc These are the basics of using a variable
Yes. int a, b; a= 2; b= 3; a= a+b;