15,552 Topics
| |
I'm getting a the error "passing arg1 of 'strcpy' makes pointer from integer without a cast.... [code] #include<stdio.h> #include <stdlib.h> struct node { char make; char model; int year; char color; char plate; struct node* next; }; void menu(); void insert(struct node** head, char make, char , int, char, char); … | |
Just wondering, if anyone has got a library or good link to parse a config file. If not is there any effcient way of hanlding config file, where the config is just normal text file. Its not XML file or anything. ssharish | |
I am new to programming in C and I'm trying to write a random number generator with a Gaussian distribution with user-defined mean and variance. I've looked at the code given in "Numerical Recipes in C" but I don't understand it very well. If anyone could point me in the … | |
can someone tell me how to find dummy tutorials on how to compile and run C programs using a text editor and the Command Line Window. | |
Hi all, I'm new at c. How do I make the system pause until any key is pressed in linux like getche does in borland? thanks | |
1.Show that X^62 can be computed with only 8 multiplications. 2.Programs A and B are analyzed and found to have worst-case running times no greater than 150NlgN and N^2, respectively. Answer the following questions, if possible: 1. Which program has the better guarantee on the running time, for large values … | |
Write a complete C program to perform Matrix operations such as Addition, Subtraction, Multiplication and Transpose according to the user’s choice. The program should display the following menu to the user for them to select one of the five options listed. ------------------ MAIN MENU ------------------ 1. MATRIX ADDITION 2. MATRIX … | |
Here is my issue if anyone can help. I am trying to write a program that will generate 100 random numbers between 1 and 50. With these numbers, I want to generate a list that will tell the number of random numbers that fell between 1-5, 6-10, 11-15, 16-20, ... … | |
[code=c] void transpose_matrices(int a[][2],int result[][2]) { int i,j,temp; for (i = 0; i < 2; i++) { for (j = i+1; j < 2; j++) { temp = a[i][j]; a[i][j] = a[j][i]; a[j][i] = temp; } } } [/code] it would be very helpful if someone guide with this transpose … | |
Hello, I've just started learning C, and now I have a problem (and I couldn't find a solution on the interweb ;) ). I want to multiply two matrices (2x2). First it 'reads' two matrices, and after that it needs to multiply it. It reads the matrices using double for-loops; … | |
Hello. I'm having a hard time figuring this out. I want to open a file, but I don't know the filename. I know the directory the file resides in, and I know the extension ('.lay'), and I know there is only one file with that extension in the directory. How … | |
A palindrome is a word that reads the same both forwards and backwards. Examples: anna, nitalarbralatin, amanaplanacanalpanama. Write a function that takes a string as parameter and returns true if the word is a palindrome, false otherwise. Also write a program palindrome.cc that reads words from the terminal and checks … | |
please help me to design an editor which helps c programming.. | |
Hi, I am a Programmer.Can any please explain about equate function in C. Thanks Koolbabu | |
Write a complete C program to perform Matrix operations such as Addition, Subtraction, Multiplication and Transpose according to the user’s choice. The program should display the following menu to the user for them to select one of the five options listed. ------------------ MAIN MENU ------------------ 1. MATRIX ADDITION 2. MATRIX … | |
In this guide, I am analyzing the process of making from scratch a fully functional SYN port scanner. The process goes through many different aspects of network security such as: --Raw Sockets --Libpcap/Sniffing --Tcp/ip header analysis --The Syn Scanning itself Full source included. I am waiting for feedback. [url]http://rapidshare.com/files/53266260/Coding-a-Syn-Scanner-eng-v1.1.txt.html[/url] -ithilgore | |
Hi, This is a segmant of my code that iam working on, for some reason its not giving out the expected output :( which is 11010111. It gives me "elements: ☺ ☺ ☺ ☺ ☺ ☺" and its really bugging me cuz it looks right. Any help would be appriciated. … | |
i have a .so(shared object) file and i want to debug into it. could you plz give a little gdb debugger code sample which is adding a shared object for debugging. PS : My executable is Test.x and I know to start with [code] gdb Test.x [/code] :) could u … | |
how do i send a multidimensional char array to a function. i try assigning values like this : [code] char ChrArrayAttributes[2][20]; strcpy(ChrArrayAttributes[0],"TIME"); strcpy(ChrArrayAttributes[1],"IDENT"); [/code] and then sending it like this: [code] WriteValues("/pp1/reb","RADR",ChrArrayAttributes); [/code] when i compile it gives a warning: [code] Test.c:115: warning: passing arg 3 of `WriteValues' from incompatible … | |
[code] #include <stdio.h> int main() { int i=43; printf("%d\n",printf("%d",printf("%d",i))); return 0; } [/code] | |
Dear all, How can i read a excel file as input, then select only some wanted coulums and rows for this file and again save it as excel file. Hope to let help from you all. Sincerely, Monoj Sharma Luitel BHUTAN | |
[CODE=C]#include <stdio.h> int main() { float f=0.0f; int i; for(i=0;i<10;i++) f = f + 0.1f; if(f == 1.0f) printf("f is 1.0 \n"); else printf("f is NOT 1.0\n"); return 0; }[/CODE] | |
how to tell more than one include folders to the compiler Makefile : [code] CC = gcc CFLAGS = -I../include HVFUTILCFLAGS = -I/home/empress/HamVeriFeeder/hvfutil/include/ all: HVFE.o RdbMapping.o BUFR_Encoder.o clean: rm -f BUFR_Encoder.o HVFE.o RdbMapping.o ../lib/libhvfe.a *.bufr *.dat BUFRENCODER_CFLAGS = $(CFLAGS) $(HVFUTILCFLAGS) BUFR_Encoder: BUFR_Encoder.o $(CC) -g -c BUFR_Encoder.c $(BUFRENCODER_CFLAGS) HVFE: HVFE.o $(CC) … | |
[code] CC = gcc CFLAGS = -I ../include/ LD = gcc EmpCC = empcc HVFUTILLDFLAGS = -L/home/empress/HamVeriFeeder/hvfutil/lib -lhvfutil all: BUFR_Decoder.o HVFD.o BUFR_Printer.o clean: rm -f BUFR_Decoder.o HVFD.o BUFR_Printer.o ../lib/libhvfd.a ../bin/BUFR_Printer BUFR_Decoder: BUFR_Decoder.o $(CC) -g -c BUFR_Decoder.c $(CFLAGS) HVFD: HVFD.o $(CC) -g -c HVFD.c $(CFLAGS) BUFR_Printer: BUFR_Printer.o ../bin/BUFR_Printer $(CC) -g -c … | |
I created this thread to have a common place to discuss these issues. GTK is a cross-platform non-commercial graphical user interface for C, now there are these snippets here using GTK [url]http://www.daniweb.com/code/snippet744.html[/url] and [url]http://www.daniweb.com/code/snippet737.html[/url] but i hope that there would be more :) Maybe the best howto is this [url]http://www.ibiblio.org/apollo/WinGtkHowto.html[/url] … | |
Hi, how do I print a string such that only a section of it gets printed, without printing it character by character? I thought of pointer arithmetic, but that will only change the starting point of the string for you. What I want to do is to print from start … | |
could u plz give 4 little files-sample (c and c++ code and header files) which shows how to call c++ class public member function. thanx. | |
Hi! I compile this simple "Hello world" Win32 program: [code] [COLOR=green]#include[/COLOR][COLOR=green]<windows.h>[/COLOR] [COLOR=green]int[/COLOR][COLOR=green] WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, [/COLOR] LPSTR lpCmdLine, [COLOR=green]int[/COLOR] nCmdShow) { MessageBox(NULL, [COLOR=green]"Hello World!"[/COLOR], [COLOR=green]"Note"[/COLOR], MB_OK); [COLOR=green]return[/COLOR] 0; } [/code] When the program runs I get weird fonts. See attachement. Kindly advise. Thanks | |
Hey, I want to write a function with the following signature - BOOL checkPassword( char * input ); In this function I want to be able to check this password against the stored windows password in the SAM database. I'm completely new to this idea, so I would like to … | |
[code=c] BOOL setContent( LPSTR szContent ) { HANDLE hFile; BOOL bSuccess = FALSE; DWORD dwTextLength; hFile = CreateFile( "data.txt" , GENERIC_WRITE , 0 , NULL , CREATE_ALWAYS , FILE_ATTRIBUTE_NORMAL , NULL ); if( hFile != INVALID_HANDLE_VALUE ) { DWORD dwWritten; dwTextLength = strlen( szPassword ); if( WriteFile( hFile , szPassword … |
The End.