User Profile
Collapse
-
better use '%' (Modulus operator) ok?... -
i mean we can access single element or all elements at a given time
ThanksLeave a comment:
-
consider the code below,
#Code:#include<stdio.h> union koder { char c; int i; double d; }; main() { union koder new; printf("\n %d",sizeof(new)); }...Code:#include<stdio.h union koder { char c;Leave a comment:
-
HI All,
I am always ready for any kind of article writting service,i can put out any article including data structures like singly linked list,doubly linked list ques and stacks
so dear Banfa,the best idea is start with a basic topic,ask for contribution of articles on the same, sort out the best and publish it here.
regardsLeave a comment:
-
could u be more specific?a little more elaboration on requirement that what u need exaclty with the code u intende to writeLeave a comment:
-
Hi,
is the below code answer your queries?
~Code:#include<stdio.h> main() { int total=0,i,amount=0; for(i=1;i<=3;i++) { printf("\nenter amount" ); scanf("%d",&amount); total=total+amount; } printf("\ntottal= %d",total); }Leave a comment:
-
-
sorry,i could not get your question correctly,if some got a better code please let me know
...Code:#include<stdio.h> main() { long i; long result=1; for(i=10;i<20;) { if((i%2)) { result=result*i; i++; } i++; } printf("\n %d",result); }Leave a comment:
-
if u are in bangalore,south india i would suggest u go to cranes varsity/mistrals for embedded training
they r doing great job.thire was a company calld suyoga,i am not sure they have closed down.Leave a comment:
-
hi,
i given a semicolon and it compiled..i am not sure of syntax of c++
see the code below
#and the out put is 1Code:include <iostream> using std::cout; main() { for ( int x=1; x<= 10; x++ ) { if ( x>5) break; cout << x <<" "; return 0; } }
let me know it is correct...Leave a comment:
-
Hi,posting the necessery kode,for what u askd,try out the string reversal by your self,if u find difficulties,pl ease do not hesitate to ask
...Code:#include<stdio.h> #include<string.h> int get_sum(int); int get_prod(int); int get_rev(int); main() { int pnum=0,rev_num,i,prod,sum; int ch=0; printf("\n enter the number");Leave a comment:
-
hai Banfa, really glad to see u explain the things from basics.But we have a rule that we dont need to give structure name,after the keyword struct,..in that case how i will have a structure definition and have a variable if that structure type...Leave a comment:
-
structure
i have different structure definitions.cou ld any one tell me why it is not taking the folowing variations
gcc produces the given...Code:ex1: #include<stdio.h> struct{ int i; // 4 bytes char c; // 1 byte char b; // 1 byte }; main() { struct a p; printf("%d",sizeof(p)); } -
sir,
above program gives many compilation errors ,listed below
refer2.c:3: parse error before '&' token
refer2.c: In function `main':
refer2.c:4: warning: return type of `main' is not `int'
refer2.c: At top level:
refer2.c:16: parse error before '&' token
refer2.c: In function `swap':
refer2.c:19: `a' undeclared (first use in this function)
refer2.c:19: (Each undeclared identifier...Leave a comment:
-
Hi Rajeev,
u can use GNU debugger,which is simply known as GDB
please make an executable of the program
steps given below
$gdb exe_name
then were ever u need to put break points, use the command 'b function name'
if u wanted to print a variable content, use "p variable name"
u can get some info by using a $man gdb
or try google, for gdb+mannual+pdf u...Leave a comment:
-
"for the below given program
#include<stdio. h>
#include<string .h>
int main()
{
char b,a;
printf("Enter the string");
scanf("%c",&a);
b=getchar();
putchar(b);
printf("\n%d",b );
return 0;
}
if i input some character like "out"
the out put will be "u" and the...Leave a comment:
-
#include <stdio.h>
int a, b;
main(0
{
/* set a and b both equal to 5 */
a = b = 5;
/* Print them, decrementing each time. /*
/* Use prefix mode for b, postfix mode for a */
printf("\n%d %d", a--, --b);
printf("\n%d %d", a--, --b);
printf("\n%d %d", a--, --b);
printf("\n%d %d", a--, --b);...Leave a comment:
-
more over when u say here return some_int_value;
it is aginst the function declaration
warning: `return' with a value, in function returning voidLeave a comment:
-
#include<stdio. h>
#include<stdio. h>
void foo(void );
main()
{
printf("\n before foo()");
foo( );
printf("\n after foo()");
}
void foo(void)
{
printf("\n inside foo");
return;
}
output
$before foo()
inside foo
after foo()[
...Leave a comment:
-
Hi,
please , can you specifically tell us,which domain u r seeking to write test cases?
if u want to test a code written in c,
u can adopt several testing methodologies
1.Unit testing
2.Functional testing
3.IMI(inter modular interface) testing
4.Functionality testing
5.system testing
methods,1-4 comes under white box testing and 5 comes in black box testing
for...Leave a comment:
No activity results to display
Show More
Leave a comment: