15,552 Topics
| |
Dear All, I am a C code to calculate prices in stock market. I pass a two dimensional array to a function as [CODE] #define DIM 3000 void grid(double tree[][DIM]); int main(){ double tree[DIM][DIM]; grid(tree ); return 0; } void grid(double tree[DIM][DIM]){ /* and do sutff on tree * } … | |
Hiz.... Can anyone help me in getting a code for reading a file in C language and counting different characters in it and then make a histogram based on the obtained results....................................plz help :) | |
hi all, plz explain me. in following code[code] int main() { int arr[5] = {1,2,3,4,5}; printf("\n *arr = %d", *arr); printf("\n *arr = %d", *(++arr)); return 0; } [/code] why printf("\n *arr = %d", *(++arr)); this line giving error: '++ needs l-value' | |
Hello/Hi, I m new to this pool of C. I wass just reading a book named "C TUTOR" this book is gr8.. but i cannot understand the subscripts of 2D arrays... I find them pretty hard.. Plz tell me wat exactly the below programme mean of suggest me some simple … | |
please make a factorial number that the output is like this: Enter a number:5 5!=1*2*3*4*5 5!=120 likewise Enter a number:6 6!=1*2*3*4*5*6 6!=720 please..help. using for loop statement only. please do not use #include<iostream.h>... use this example: #include <stdio.h> #include <conio.h> ........etc. please...help me... | |
hi when I use this with my program i have msg tell me about the warning in my program please any one explain it thanks | |
I have an assignment that calls for me to only use standard C. I am currently trying to take in input from a file using fopen() and then take in lines from the file using fgets(). The original problem was that fgets() quits taking in input after six lines. "Something" … | |
Hello Everyone, I am developing a kernel module which acts as a sniffer and also a module which edits the TCP packet window size as per requirement of the admin. And in the process I developed this kernel module which is tainting my kernel (Opensuse11.2).The sniffing module developed by me … | |
Dear All, I am trying to code a multistage timer which prints out a line of text. The timer countdowns from a certain point in time and then prints out a line at times defined in an array. The array is sizable so there is no fixed length. The user … | |
[CODE]#include<stdio.h> int main() { int yo[4][4]; int b; int c; for(b=0;b<12;b++) { c=0; while(c<5) { yo[b][c]=(b*c); printf("a[%d][%d] = %d\n",b,c,(yo[b][c])); c++; } } getchar(); return(0); } [/CODE] The above code starts with b=7 why!!!!!! compile the programme and u will understand my problem .. plz helpp...... help... Thnx in advance........ | |
hello, i am new to vc++, can i write and run c program in vc++? if yes, please explain how to do so. | |
for exmple i want to convert this string "21 4 5 7 - + -".. how can i get the numbers separately and parce it with the other symbols.. | |
I am having trouble with this array. I need to sort the second column in descending order. Please have a look and tell me where I went wrong. Much appreciated. [CODE]const int sizex=20; const int sizey=2; void descend(int arrayx[][sizey],int sizex,int sizey); void printarray(int arrayx[][sizey],int sizex,int sizey); int main() { int … | |
To start off with this is a homework assignment for my Operating Systems course and I am stumped. The prof wants us to read in a source code file and take out all the comment lines and then output the file back into a new source code file. We can … | |
Hey everyone, this program's been killing me. I have to create a program that takes another program as input and counts the lines. Pretty simple, except that to do this, you have to count semicolons which means you have to negate semicolons that are comment text or within double quotes. … | |
I've been given a practical where I have develop a random bubble sort algorithm and I've created one already where the user enters the elements needed to arrange the numbers, I now have to use a random number generator that uses a set of 10 random numbers from 1-10000 and … | |
I keep getting the warnings such as "warning: passing argument 2 of ‘strcmp’ makes pointer from integer without a cast" about strcmp and strdup. I'm pretty new to C and I feel like I've tried a million things with no luck...I don't really get what's going on. Any help would … | |
my true objective is to read back for the file into the structure but i am just not making any progress. I have placed an attachment of the file. I am just not comprehending all of the codes that i am seeing from the snippets. So can someone please give … | |
Hey, I have another problem... I am using a FOR loop which is making a lot of lines. The problem is that the new lines "runs over" the first lines because there is no room for the new ones. In shortly, when a new line comes and have no room, … | |
I these contents below written to a file.I want to user to input a number and i will then scan the file to see if it matches my registration number. But in doing this i just want to get the 1001 from the first line. REGISTRATION: 1001 NAME Donellie Whyte … | |
Guys I am not a good C programmer. I ahve experience with object oriented paradigms such as Java and C# but I never programmed in C or Pascal. I have done some tutorials in C and I seem to grasp some of the ideas of the language but as I … | |
Hi everyone, I'm kind of stuck, is this the correct notation to compare a char to double quotes? variable == "\"" | |
please help me on this.. i have to make a payroll system using turbo C program but i don't know how to make it.. pretty please...:) | |
IF i write to file REGISTRATION NUMBER :1001 how can read back from the file the 1001. Thank you for all your help,i have gotten other hints but they don't seem to work | |
Hii friends.. this is [B]uday[/B] here.. i'm new to Daniweb.. [B]I want to learn programming in C .. Pls can u guide me hw cud i b a good programmer?.... [/B] | |
How can i call (execute) a file (with ".c" extention) from the particular path without including it into main file ? Now the file which we have to call from particular path is containing only a function (without "main()")..... | |
Hello all, I have been assigned in my class to come up with a program that is written in c and generates prime numbers from 2 to n. I have coded the problem but i have a problem. Any numbers greater than 6479 will not return the results that I … | |
In the following program though most of the working part of the program is commented out, it gives seg fault. reducing the value of MAX to say 10000 removes the seg fault. Why is this happening? it should be only 1 MB only. Is 1 MB too big for an … | |
A discrete time counter oscillator expressed in C code wil produce sine wave like signal: P,P+ and g represents the current phase, next phase value, and increment value respectively. To implement this in software the register is simply a variable that retains its value between updates and the look up … | |
Hi, I recently came across a code which had the below lines. [code] unsigned int n = 10; n ^= (unsigned int) - 1 ; [/code] It is not clear to me what the second line does. Anyone can help please :) |
The End.