Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
0% Quality Score
Upvotes Received
0
Posts with Upvotes
0
Upvoting Members
0
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
0 Endorsements
~6K People Reached
Favorite Forums
Favorite Tags
c x 8
c++ x 5
Member Avatar for sdinu96

If u type top command in terminal u will get like this.......... For eg. PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 31253 user1 16 0 2112m 2.1g 1764 R 37.0 53.2 0:39.89 firefox 31249 root 16 0 2112m 2.1g 1764 R 15.5 53.2 0:38.29 gtk-gnash …

Member Avatar for vijayan121
0
168
Member Avatar for sdinu96

Hi everyone, I don't know how to calculate cpu and memory usage information of a process.I know this information is located in /proc/pid/... but where............because i want to display this information in C++ without using "gliptop" library........... Please help me ........even if possible i need "top" command source code in …

Member Avatar for sdinu96
0
177
Member Avatar for sdinu96

Hi everyone, I want to write a code in C++ so i want to knw information about /proc in liux . where if we give the command "top" in terminal it will show all currently running information like this if i want to display these information using C++ code .so …

Member Avatar for Nick Evan
0
57
Member Avatar for sdinu96

Hi everyone I want to open the Directory like this using C++ in linux eg : /proc/1/status where proc and 1 is a directory and status is a file,which i want to access(i.e)this file i have to copy to an string to access some information..................can anyone help

Member Avatar for Ancient Dragon
0
64
Member Avatar for rajina

Command line arguments in C #include<stdio.h> int main(int argc,char *argv[]) { FILE *fp; char c; if(argc==2) { fp=fopen(argv[1],"w"); while((c=getchar())!=EOF) { putc(c,fp); } fclose(fp); fp=fopen(argv[1],"r"); while((c=getc(fp))!=EOF) { printf("%c",c); } fclose(fp); } return 0; } How to run this program in linux? I have tried these steps: 1. open terminal in linux …

Member Avatar for rajina
0
181
Member Avatar for sdinu96

why computer takes more execution time when a function is called ? i want theoritical explanation.............that is what happens internally.......... this is diadvantages of Function Why it takes more execution time ?

Member Avatar for abhimanipal
0
102
Member Avatar for sdinu96

I want database management in C To ADD,LIST,DELETE,INSERT using structures and files..........not in linked list.............. can anyone help me out....because this is the first time to do long and some what complex program for me

Member Avatar for abhimanipal
0
4K
Member Avatar for sdinu96

[code]#include<stdio.h> #include<stdlib.h> #include<string.h> struct name { int a; char b[10]; char c; }; int main() { struct name *p; p = (struct name *)malloc(3 * sizeof(struct name)); char *n; n = "12345"; n = (char *)p; n = (int*)n; /*this is not correct . in doubt....change correctly*/ strcpy(n+(sizeof(p->a)),"ALL"); *(n+sizeof(p->a)+sizeof(p->b)) = …

Member Avatar for abhimanipal
0
109
Member Avatar for sdinu96

{ int i = 25789; char *p; .............. .............. printf("%d",*p); /* (*p) should give in printf*/ } dont assign p=i ............apart from this how we can typecast this program so that we can get interger value tp pointer p.............please help me this

Member Avatar for Ancient Dragon
0
84
Member Avatar for sdinu96

[code]#include<stdio.h> #include<stdlib.h> #include<string.h> struct name { int *a; char b[10]; char c; }; int main() { struct name *p; p = ( struct name * ) malloc ( 3 * sizeof ( struct name ) ); char *n; n = ( char * ) p; *n = 275; strcpy ( …

Member Avatar for Banfa
0
374
Member Avatar for sdinu96

[code] #include<stdio.h> #include<stdlib.h> #include<string.h> struct name { int a; char b[10]; char c; }; int main() { struct name *p; char *n; n = (char *)malloc(3 * sizeof(char)); // in this why 3 means.. its my condition n = (char *)p; n->a = 3; // this line is showing error …

Member Avatar for Banfa
0
94