19,876 Topics
![]() | |
Hello, I am trying to learn C and would like to create a program that opens a text file (already created) and reads out the words contained within onto the screen. Not to sure where to stat with this, please can someone give me some ideas? Thanks in advance. | |
Hello all, I am badly in need of a simple to use Matrix library for C++ that can handle complex data type.. I am working in Bloodshed Dev C++ under windows XP. Waiting anxiously if anybody can be of help!! Imtnan ![]() | |
I want to read the registry of usb [COLOR="Red"]HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR[/COLOR] in this Name Type Data start REG_DWORD 0x00000003(3) when double click it gives value in Hex 3 How to read this value 3 or data 0x00000003(3) How to create this code in c language??? How to do it guys If any … | |
hi all, i am developing an browser in c from scratch, parsing i am able to doing and now in rendering i am facing some problem, so anyone have any Experience on webrowser in c help me out. thanks & regards sanjeev sharma | |
I am trying to solve a problem from a lab challenge. I'm having trouble on how to output the table and it must be done in [B]top-down design.[/B] Use a two-dimensional array to solve the following problem. A company has four salespeople (1 to 4) who sell five different products … | |
[B]Hi there[/B] I am really new in C programming (about 3 weeks). Before I begin my question I have to excuse because of my bad English. My question is on reading a file that contains double and integer type numbers. For reading file I use fgets() that read a line … | |
A component developed in C# is used by application written in VB 2005. The component includes a field for data entry of numeric values, the field becomes active for data entry upon a mouse (touch-screen) click. When the component's data entry begins I want to activate a virtual keyboard on … | |
Hi I'm still in the basics in c++ and I really need some help in coding my 1st semester's project. I am required to create a program that is to be used at a tollstation to keep account on the number of vehicles using the road, the fees charged and … | |
So uh, i need some help with these functions..i gotta reverse, but i do not have the functions that can make it lowercase, or remove punctuation [code=cplusplus] #include <iostream.h> #include <string.h> char your_string[256]; char new_string[256]; void ReverseString(); void main() { cin.getline(your_string, 256); ReverseString(); cout << ReverseString(your_string) << "\n"; } void … | |
Hi there, Im new to this site, and I just have a question of something that I have been trying lately in the C language. I need to put a whole array in a shared memory file (using POSIX). I have no problems putting simple int* in shared memory. I … | |
Hi, need some help with this one. Here is the question: Compose an algorithm for a program that creates a list of words encountered when reading a series of text files. Write a program to open, and subsequently close, each input file, terminating should an attempt to open any file … | |
Hi all, I am new to Programming,can anyone guide me how to go about this senario, The requirement is like this, In a System there are 8 faults as below, Fault -Fault Code-Description INF1-26-unknown Drive rating INF2-27-for Unknown or Incompatible Power Board INF3-28-ISL communication Fault with Power Board INF4-29-Invalid Industrialization … | |
Hi All, I need help to sort out my C Practical question. I am new to C and looking forward to do programming can some one help for the following. 1. How to write a program in c to calculate file size from KB to Bits? 2. How to write … | |
Is there any way to pass a class as a function pointer. for example: [code=C++] int compare(int a, int b) { return a - b; } void sort(int *ar, int (*pf)(int, int)) { //a sorting algorithm. } class MyClass { bool condition; public: int compare(int a, int b) { if … | |
Hey guys i have a small question here. [CODE] float angle0; printf("\nEnter Original Attack Angle Value in Degree: "); //input angle scanf("%f", &angle0); while(angle0<-180 || angle0>180) { printf("\nEnter Valid Original Attack Angle Value in Degree: "); scanf("%f", &angle0); } [/CODE] i dont get it when i put in 180 it … | |
someone please help me to write a program that would replace all occurances of a substring in a string ,with a given string.if the input string is "the the the the",& if the substring to be deleted & the substring to be substituted are "th",&"ase" respectievely then the output should … | |
Hello, I am a first time poster and not that familiar with HTML codes or uses. I did try to look this one up and could not find it. When I enter 26.2, it gives me 26.20001. I do not understand where that 1 is coming from. Thank you [CODE]#include … | |
hello, I'm working on a personal project and I was looking for some help. I am writing a program that needs to store user profiles in an external file (.user_data.dat). Problem is that anyone with half a brain can find the file and with any text editor look at the … | |
Hi all, I hope this question is in the correct area of the site. If not, someone please advise. I am creating Excel pie charts using C# Excel Interop. My problem is that my charts (plot area, I suppose) are never in the horizontal center of the chart area. However, … | |
Hey frnds, i have faced the interview question-- Suppose time is 11:00, What is the degree at this particular time??? Suppose time is 3:00, What is the degree at this particular time??? I have clue abt this question,plz reply. | |
Hello. I need help with a thing. I have a file (sound file) I will send via controller area network and therefore can only send data about 8 byte or 8 vector as data [8]. This is sent away with the command sendfile () And I need help how I … | |
the last for loop i declared it inside, which doesnt work as a c program its c++ i need to declare it out side how do i do that? [CODE] #include <stdio.h> #include <string.h> #include <ctype.h> // Our function declaration saying it takes one string pointer and returns one string … | |
hi, i need help.. i have been working for about 4 hours trying to figure this out and im still lost.. the answer is probably simple but im new to c++ so please forgive me. off a site called informit, the following code is posted: [code] #define NELEMS(A) (sizeof(A) / … | |
Hi, I'm trying to make this code works but with no luck so far, I have two problems 1. I'm reading from a file lines and then executing them but the last line goes into an infinite loop 2. Another problem is I don't think I'm using "wait" properly as … | |
So I'm writing a program in C that reads in a bunch of words from an unspecified number of files and I'm to print out the top N words in the file. I'm using a hash to store them in, where each bucket is a linked list. The lists are … | |
Guys hello, i`m a new member here [IMG]http://images.devshed.com/fda/smilies/smile.gif[/IMG] Hello to everybody...I need urgently help... I have an assignment for C++. "We have a collection of emails. This collection has emails from Linguist.org, these mails are legal. these are in a file called ling_filenames.txt. We also have a collection of spam … | |
You will read in a file supplied from the commandline (filename.ext,) and write/overwrite out a file which will be called (filename.ext.mng.) This file will be essentially the same as the original file, but will have all characters on all lines the reverse of the original. For example: The original file … | |
Python has some nice features for working with paths: [url]http://docs.python.org/lib/module-os.path.html[/url] Does anybody know of any C/C++ functions, techniques or libraries to do something similar? For example, if I'm passed a path on the commandline as such: x = "~/mystuff/../myfile.txt" In python I could get the absolute path as such: os.path.abspath( … | |
iam a 1st yr b.e stucent.i was attending my c.p lab viva.i was asked to write a program that would exchange 2 variables without using a third variable.i could'nt do it.i know how to exchange the values by using a third variable.someone please answer this question. | |
[CODE=C]int test[2]; pipe(test); FILE *to, *from; if ((to = fdopen(test[1], "w")) == NULL) return 1; //error: could not create stream if ((from = fdopen(test[0], "r")) == NULL) return 1; //error: could not create stream fputs("test text", to); char testBuff[5]; fgets(testBuff, 5, from); puts(testBuff); //This should display 'test' in console - … | |
I am having trouble reversing the words in a sentence. For example "a line of text" should be printed "text of line a". So far I can only print the last word, it is probably obvious but at the minute i just can't see how to do it. Any help … | |
[code] #include <cstdio> #include <cstdlib> #include <iostream> using namespace std; static const int password = 1705898; int main() { int secondnumber; while(true); { cout << "Enter Password"; cin >> secondnumber; if (password = secondnumber) { cout << "Welcome Matthew"; } else { cout << "password Rejected"; } } system ("PAUSE"); … | |
Can any onbe say me the exact difference between a pointer (*p) and the array p[]???? I mean to ask that when we pass an array to a function by reference, we can have both in the function definition, the * or we can manipulate the array too... But there … | |
I am trying to do a program that produces random limericks and this is what I have so far... I am posting this again, because I don't think the first one went through. Sorry if it did... #include <stdio.h> #include <time.h> #include <stdlib.h> #include <string.h> #include <ctype.h> int main(){ char … | |
Write a function that fills in a given matrix with the given numbers so that the sum of all columns and all rows should be equal to the same number. The prototype for the function should be void fillMatrix(int mat[][MAXSIZE], int numbers[], int rowSize, int colSize, int sum); For example, … | |
Hi all, I have read an YCbCr image by using fopen, fread using C. I wanted to extend this to read multiple frames like in a Video. How should I proceed? I should take a while loop, but then what is the limit of the counter. After reading those images … | |
I need help changin this program around right now it tellls rather the number is prime but i need to make the program tell rather the user puts in is even or odd heres a lil code let me knw if i need to put all the code on there … | |
The problem is that my program crasches when at line 13. Pot10 i an int and lgth is an int so whats the problem? I can't figure it out:( [CODE=c]typedef struct ArrInt{ int intM[100], lgth; } megaint; void scanMeg(megaint *x){ int Pot10 = 0, ret,IntArr[100]; char c; while( (c = … | |
Hi, I've question regarding visiting and printing nodes for tree traversal. the main purpose of my program is to create tree for an arithmetic expression and then perform in-order and post-order traversal on the tree. The structure tree need to be hard-coded in the program using linked-list/pointer stored in one … | |
I wrote this code to re-create the classic race of the tortoise and the hare and everything compiles fine. Just the logic is messed up. When I run the program all I see is BANG AND THEY'RE OFF and who wins. I should be seeing a T for the Tortoise … | |
Hi everyone, I'm new to C programming and I'm trying to write a program that can print text in columnar format with a maximum width. I've been trying with this but I get a seg fault. Am I going about this the right way? Any help would be really appreciated. … | |
Hi there, I'm having a problem with adding a data structure to an existing linked list that has highlighted a gap in my knowledge about the latter. Briefly, what I am trying to is add a 'particle' to the end (i.e. appending) of an existing linked list of particles. My … | |
Hi Sir Write a C program to count and print the total number of: upper case letters, i.e. ‘A’ to ‘Z’ lower case letters, i.e. ‘a’ to ‘z’ | |
hello i am trying to figure out the output of this specific code [CODE]int main() { int i , parent_id , ans ; parent_id = getpid() ; for ( i = 1 ; i <= 5 ; i++ ) { if ( getpid() == parent_id ) { ans = fork() … | |
Hello char **pOutData; /* Output results */ char *ptoken I have a pointer which contains the following hdjhasdjkhasd;stephenjohnson;647823463;dhasdjhaj I want to work through and get out just stephenjohnson I have the following so far, which does not work....any help? [code=c] for ( size = 0; size < b2b_data_drill_nNoSelect; size++ ) … | |
Hi all, new here so have 1 question... Am wondering this forum has a section for Windows Programming discussions | |
Hello, I'm still getting the hang of coding (just started a few weeks ago) so this may seem like a daft question. I keep on getting three errors when I run my code: ode_functions.c f:\ode_functions.c(41) : error C2296: '^' : illegal, left operand has type 'double' f:\ode_functions.c(41) : error C2297: … | |
Hey, im trying to use pointers with a struct. I am having an issue in the function searchData. I can not get the pointer to compair with the string, it is still just compairing the actual adress or something else. Not sure if i even passed it right. Please help … | |
I just finished up the final touches on my C Project (at least I hope that's the last of them). Anyway, it's due Friday (10% of my overall grade) and I'd like to have some quick feedback (constructive criticisms and complements) before I had it in. It was suppose to … |
The End.