15,552 Topics
| |
Hello all, I have been a member here for some time, i must admit this is my first post. I have read the posting rules, lets hope my title is considered "meaningful". i have no code snippet, yet. I have just hit a sudden wall in my heap programming. I … | |
[B][COLOR=navy]hi my name is qurat .. i have a small problem :rolleyes: i dunno how to do this program .. i have tried it several timez but it is giving some or the other error[/COLOR][/B] [B][COLOR=#000080]here it is:[/COLOR][/B] [B][COLOR=#000080][/COLOR][/B] [COLOR=#000000]Implement a Queue using two Stacks (implement Stack using link list).[/COLOR] … | |
Hello, I am currently learning (or really just begun) Assembly (my first programming language, by the way) and am wondering once I become somewhat good at Assembly, should I start picking up the C language. I know that several languages are based upon it, and I am even planning on … | |
Hi, I want to do the following steps one by one 1. check whether given file is exists in the directory or not 2. if exists open the file 3.read the first line and store the values 4. got to the last line of file and store the values 5. … | |
hello i have got little problem :) create a c program which starts with 3 processes the first proccess generates 50 random numbers and writes them inti common memory. the second proccess reads them and whrites the even numbers in file A,the odd numbers in file B. [CODE]#include <stdlib.h> #include … | |
I am wondering about this if I had a program that contained this: if (0 <= X and X < 49) output "you fail" What will be printed if the input is 0? would it say you fail? I was thinking it was worded wrong and it should read:if (0 … | |
| I want to read files and folder names from directories. I have used the following code. But the problem is that in the output the file name gets truncated.[I](See the output below)[/I] [code=C++] #include <dirent.h> #include <stdio.h> #include<conio.h> void main(void) { clrscr(); DIR *d; struct dirent *dir; d = opendir("."); … |
To whoever is using the following code for timing code execution in C Originally Posted by [[B]B]vijayan121 [/B][/B] [code=c] #include<time.h> blah blah main() { clock_t start, end; double cpu_time_used; start = clock(); /* whatever */ end = clock(); cpu_time_used = ((double) (end - start)) / CLOCKS_PER_SEC; } [/code] if you … | |
I have written a code for maximum power point tracking. The purpose was to create DLL file and use it in a circuit base simulation program. I used Microsoft visual c++ 2008 express and created that DLL file but I only get first value from the created array in C. … | |
when i print out a big answers 13100000000000000 i wanted to say 13.1e12 this should happen to all different answers that come out | |
Hai guys, I have quite a large program here that I don't seem to understand. The program, Bow Vice Jet (an anagram for object view) is meant to display WaveFront .obj files. However, it quits when it loads a specific file while on my computer, while on another it does … | |
[CODE=C]FILE* f = NULL; fclose(f);[/CODE] Terminates with: 'No source available for "fclose@@GLIBC_2.1() " ' [CODE=C]FILE* f = NULL; ftell(f);[/CODE] Terminates with: 'No source available for "ftell()"' Why those functions does not return error value but terminate whole program? How can I safely tell if file is opened in C and … | |
In this work you will materialise a algorithm that solves the problem of Stable Marriage. In this problem we aim at "n" men and "n" women and our goal is the contracting of constant marriages between men and women. Obviously each man can be wedded only one woman and one … | |
Well I tried to look for any posts on ranking arrays, but all I ever really got were stuff about Google's ranking system. Anyway, I have two arrays. One is arr[] which is the original array, and rank[] is the indexing array. So if I were to print arr[rank[0]], it … | |
Hi, This program reads parameters from parameter line : program.exe data.txt result.txt (or somth.) , then takes date from data.txt and writes it to buffer, then program divides buffer to lines , writes to stack, and finally it should pop lines to file, but there is an error doing that... … | |
Hai all, I ran into a strange issue I never experienced before. Pointers are passed to function, the function allocates memory to them with calloc, and right before the return sanity checks if the pointers still != NULL. That check succeeds, but upon returning and sanity checking in the calling … | |
Hi guys, I have been working on this for 13 hours straight now, and I am going out of my mind. I have a final due tonight and I cannot figure this out at all. The program is basically a product database for a sporting goods store, and I have … | |
Hi Again, If I have this 2-D array stored in [B]s1[i][j][/B] : [CODE] one two three four[/CODE] And I wanted to copy the whole row IF the first letter of that [B]row ==o[/B] . How Can I do that ? assuming that the destination array is [B]s2[k][l][/B]. I am confused … | |
When I searched the web, I found an intersting program, I dont think I can explain a bit. But, I would like to share it. It displays my home country thats the most I can say about it! Here goes, [CODE=C]#include<stdio.h> main() { int a,b,c; int count = 1; for … | |
| |
How to get lpBaseAddress to pass it to : BOOL WINAPI Toolhelp32ReadProcessMemory( DWORD th32ProcessID, LPCVOID lpBaseAddress, LPVOID lpBuffer, DWORD cbRead, LPDWORD lpNumberOfBytesRead ); It will be very helpful to me if someone can provide a snippet of code how to achieve that. Thanks a lot. | |
Hello All! I am trying to do something simple. Which is why our application is failing miserably;) Anyway, I am attempting to use the itoa() - integer to ASCII function to convert an integer value, lets say [B]123 [/B]into [B]"123"[/B]. The code compiles successfully, however during the linking, it says … | |
Okay so I'm pretty sure I've completely destroyed this code. All I'm trying to do is send the user-inputted product info into a binary file to display when the user chooses the report option from the menu. I'm so confused though and I think I really screwed it up. [CODE=c] … | |
Hi all, Need some info on "how to use or implement timers/threads/polling mechanism in c language". Need to run the same piece of code on both platforms(windows + linux). Can anyone of you guys suggest me something :) Thanks in advance! ~Manoj | |
I am attempting to write a file matching accounts receivable program. So far I have written the master file that contains the balance of clients and a transaction file that contains the transactions. But I don't know how to match the account numbers of these files so that i can … | |
Hello World Ive got a question. So basically ive got a program that asks you which file to open, and once u type in one, it dumps the contents on the screen. The contents im dealing with is a list of numbers. So my question is, how can i get … | |
I want to rename file with name of ip address like (192.168.1.55.txt) In xyz.txt file have ip address. I m finding this ip address but rename giving problem??? [code=c] #include <stdio.h> #include<conio.h> int main () { int result; char ipadd[20]; FILE *pFile;; pFile = fopen ("xyz.txt" , "r"); fseek(pFile,172,SEEK_SET); fgets … | |
Is there is any function through which i can get specific number of integer like we do through getchar() funtion .I AM USING TURBO C 3.0.HELP WILL BE APPRECIATED. | |
i know how we can use logical operators.....but how do we use bitwise operators..... | |
Hi everyone. I got a total newbe question and i am new to c programming. I want to write a program that will executing commands , written in separate text file. Lets say, in perl i got something like that: [CODE]open (F,"<file.txt"); $x = <F>; if ($x == "2"){ system … |
The End.