15,552 Topics
| |
1)Can you suggest me how to assign a pre-defined 2-dimensional array to a pointer.The intension here is to pass 2-D array to a funtion so that changes in the function will reflect the 2-D array . [code]void main(){ int array[40][40]; fun(array); } void fun(int **array){ ........}[/code] The above code is … | |
Hi, I m an engineering student. I wanted to know how r pointers supported in c . How is that any levels of indirection is supported. | |
I am writing a program for my college class :eek: It has to record a password, but it cant display it on the screen. It is a unix based enviroment. Does this look correct to you guys? [CODE] main() { int i; char buffer[80]; initscr(); printw("Please enter a password => … | |
Hi all!!! I have been tearing my hair out trying to figure out how to make the below program calculate and display the total sales tax for each location. If anyone can please look at my code and send me in the right direction, I am hoping I can get … | |
In a statement like this [code] void mousebuttonhandler(int button, int state, int x, int y) { int counter; if (button == GLUT_LEFT_BUTTON && state == 0) counter ++; printf("Mouse button event, button=%d, state=%d, x=%d, y=%d\n, ", button, state, x, y); glutPostRedisplay(); } [/code] It appears that im trying to count … | |
[code] Please look at the following code snippets: char str[]="abcd"; // Gets stored in stack frame. char *str="abcd"; // Where does this gets stored? In case of first declaration ie char str[]="abcd"; the string "abcd" gets stored in the stack frame of the invoked funciton. I wonder where does the … | |
Hi All, I am using system function to decrypt an encrypted file, But it's taking too much of time, as a result of file access i want to know how to store the output of system( ) function into local variables instead of a file. Code goes like this. sprintf(syscommand,"des … | |
here is my code i get an error of call of non function in lines 29, 34, 39 and 44 apprecite help or an alternate code if possible here is code [CODE] int main (void) { char desiredgrade; double min_average; double currentaverage; double weight; double score; printf("Please enter your desired … | |
It is not allowed to declare a variable of same structure type but it is allowed to declare a pointer. For example, [code] struct node { int a; struct node x; //not allowed struct node *pnext; //allowed }; [/code] My question is when we can declare a pointer of same … | |
how to generate a state transition diagram in c.. give me the implementation steps | |
Hi, I've c source code developed in 32-bit linux machine. Can I run it in 64-bit linux machine. Thank you. Santos | |
Hi, Actually my program will be read some input, as example :- 123 456 789 123 567 456 Then, I want to copy all the data into array and filter out any duplicate or same record..Finally the program will be print the result without duplicate records ? Could somebody guide … | |
I have an assignment that asks me to explain the "order of complexity" of an algorithm. Can anyone explain what that question means? Does that mean what happens first and so on? Thanks. | |
actually i dont have complete concept about bigO notation that usually used to find time complexity my question is in bigO notation why we ignore constant for example f=100n we say that our algorithm has order of n time comlexity or order | |
Plz send code for implementation of shuffle game using c and Graphics. Thanq | |
how to run an audio file in C programming language as we access a textor any other kind of file........ | |
Please help can you help me debug my code i cant display the result and the computation for sum is error... help me please :sad: [code] #include <stdio.h> int i,counter; float sum; struct cgrade { char course[50]; float credit[50]; float grade[50]; }; struct cgrade GPA[50]; main(){ printf("Enter number of courses … | |
i am a little bit confused about the actual usage of the find function of map i have say a vector<string> and i want to return the relative position (or iterator) of a key (of type string) in this vector. now, the find function accepts only one input which is … | |
Again, I don't know what I've done wrong. [code] #include <iostream> using std::cout; using std::endl; #include <cstring> using std::strcpy; using std::strcat; #include <cstdio> using std::sprintf; void destroyMultiCharArray(char * * anArray, int size) { for (int i = 0; i < size; i++) { delete [] anArray[ i ]; } delete … | |
Hello, I seem to be having some C language probs. I just need insight on how I can write this program: a program that reads input , and can replace a char with another one(e.g if I type k, it should replace it with a) using getchar and switch.. case … | |
I'm trying to use scansets to filter out out some textfiles. #include <stdio.h> int main( void) { int i; char str[ 80], str2[ 80]; scanf("%d %[abcdefg] %s", &i, str, str2); printf("%d %s %s", i, str, str2); getchar(); return 0; } When I input "123abcdtye" I expect the output to be … | |
Hi, I was asked to go over this block of code and explain what it does. Let me know if this is correct, thank you! [COLOR=DarkGreen]It selects a random EXE file and checks if the first line has the 1234567 signature. If it does it goes to the Subroutine I-executable … | |
i am trying to use a boost library [CODE]#include "boost/date_time/gregorian/gregorian.hpp"[/CODE] and my source file is in the same folder as boost. however, during compilation i get errors that directories that gregorian.hpp links to (boost/date_time/compiler_config.hpp) could not be found. i've checked that all the files that gregorian.hpp links to are in … | |
SIr, I wanted to know the C Statement for adding two numbers without using + sign.. Anyone can help me to solve this..... ThanQ | |
Please help me in knowing from where I will be able to find "gdiplus.h". Just because of this file Program is showing an error "FATAL ERROR C:1083 : cannot include open file 'gdiplus.h' No such file or directory" | |
Hello everyone. I know the API of an operating system is a collection of functions within the kernel that are available for applications to use. My question is, how do you call these functions into action from within a C program, if you're compiling the source to run on Linux? … | |
Can anybody tell me what are file descriptors in C?? I searched the net but can't clear my concepts!!! | |
Hey guys, I was wondering if anyone can help me in terms of using atoi to get my my results to add the 1's of my binary output and then join them together... eg. 110101 and 100101 is 4 and 3 = 43. I was thinking of integer dividing the … | |
Hi, I am using windows , and I wanto know if there is any api that tells me if a directory exists in windows? Thanks , [I] Ishwar[/I] | |
Hi all, I am very new to C code and was wondering if someone could please help me. i am using a program that gets run through a windows command prompt and outputs the result to the command line screen by default. i was trying to get it to output … |
The End.