No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
14 Posted Topics
Hi all! I am trying to listen to plug in/out event for headphones while in background. The problem is that while the events are generated in real-time, I am not able to do handle them in real-time. Whatever code I run in the background gets executed all at once when … | |
Hi all !! I am planning to do a masters in computer science from a US university. I am not sure which field I should specialize in. I have my interests, but job prospects are also important to consider, which I have little idea of. I am listing the specializations … | |
Hi all !! I am new to Fortran. Please see the following code: program exp_realloc implicit none integer,allocatable,dimension(:,:):: array integer::i,j allocate(array(3,3)) write(*,*)size(array,1)," ",size(array,2) do i=1,3 do j=1,3 array(i,j)=i*j write(*,*)array(i,j) enddo write(*,*) enddo CALL func(array) end program exp_realloc subroutine func(array) integer,dimension(:,:),intent(in)::array integer::i,j write(*,*)"********* Inside subroutine **********" write(*,*)size(array,1)," ",size(array,2) write(*,*)array(1,1) write(*,*)array(1,2) write(*,*)array(2,1) … | |
Hi all!! See the following code: #include <stdio.h> int main() { union a { int i; char ch[2]; }; union a u; u.ch[0]=1; u.ch[1]=0; printf("%d %d %d\n",u.ch[0],u.ch[1],u.i); getch(); return 0; } The output that I get is: 1 0 2130509825 Why am I getting this number? What I think the … | |
Hi all! I was experimenting a little with scanf. I am posting the code and the outputs I am having prolems understanding: #include <stdio.h> int main() { char a,b,c; int d,e; scanf("%c%c",&a,&b);//-------------------(1) printf("%c %c\n\n",a,b); scanf("%d%d",&d,&e);//-------------------(2) printf("%d %d\n\n",d,e); scanf("%c abc",&a);//--------------------(3) printf("%c\n\n",a); scanf("%c abcdefgh",&a);//---------------(4) printf("%c\n\n",a); getch(); return 0; } In (1): Doesnt … | |
Hi ! I want to get a jdbc DataSource through JNDI. I am rather new to JNDI, and I dont know servlets,etc. Whatever tutorials I find on the internet show how to do this using some server like tomcat, etc. I want to make a simple jdbc program in which … | |
Hi ! I know this is a strange question to ask here, but I didn't know where else to ask it.:-/ I am doing my B.Tech in computer Science in India and plan to do an MS after wards. I want to get a job eventually, preferably in India. (But … | |
As the title says it, I have made a program to implement adjacency list representation of graph. I wish to use it in implementing various graph algorithms like DFS, BFS, Dijkstra, etc. The program works fine for the test cases I put in it. But I am sure that there … | |
Re: I am not very experienced in programming, but I think you can do this without using any of the functions like atoi(), etc.... Here's what comes to my mind: 1. Input the 'number' in the form of a string 2. for each character in the string, u can check if … | |
Hello Everyone !! I read a program to create a simple moving banner from my book Java Complete Reference by Herbert Schildt, and after a few days I tried to make it myself from what I understood then.....but unfortunately mine doesnt work properly, even though I think I've done everything … | |
I am searching for a book(s) which explains things like the following - 1. Difference between memory allocation of local and global (or other static variables)....? (or why i cant initialize a global variable more than once outside main and all other functions) 2. Holes in structures, and structures and … | |
[U]see the following code-[/U] [code] #include<stdio.h> #include<conio.h> struct emp { int age; char name[6]; }*e; void main() { printf("%u\n",&(e->age)); printf("%u\n",(&(e->age)+0)); printf("%u\n",(&(e->age)+1)); printf("%u\n",(&(e->age)+2)); printf("%u\n\n\n",(&(e->age)+3)); printf("%u\n",(&(e->name)+0)); printf("%u\n",(&(e->name)+1)); printf("%u\n",(&(e->name)+2)); printf("%u\n",(&(e->name)+3)); printf("%u\n",(&(e->name)+4)); printf("%u\n",(&(e->name)+5)); printf("%u\n\n\n",(&(e->name)+6)); printf("%u\n",((e->name)+0)); printf("%u\n",((e->name)+1)); printf("%u\n",((e->name)+2)); printf("%u\n",((e->name)+3)); printf("%u\n",((e->name)+4)); printf("%u\n",((e->name)+5)); printf("%u\n\n\n",((e->name)+6)); } [/code] OUTPUT------------------------------- 0 0 4 8 12 4 10 16 22 28 … | |
[code][/code] Hello everyone ! I am still a beginner, and am posting the code in which I have problems - I compiled it in VC++ 6.0 standard edition, and it gave two warnings and no errors. The warnings disappear if i use double everywhere instead of float. the warning (same … | |
I am doing B.Tech in computer science and I am in the 1st year (I have almost completed 1st year) I want to learn a language in the forthcoming summer break (2 months) between the first year and second year, and am quite confused if I should go for [U]C++ … |
The End.