19,876 Topics
![]() | |
Hi Guys , If I have a file compouse by words one per line how can I get all the words to put them together and have them separated only by one space. Also how can I make sure I'm extracting only words and not numbers or special character. I … | |
sory im complete newbie i have [code]include <stdio.h> int main() { int x; for(x=1; x < 10; x++) { printf("%d\n second ", a); } return 0; }[/code] [code]for.c:1: error: syntax error before ‘<’ token [/code] | |
ive got this [CODE]#include <stdio.h> #include <unistd.h> int main() { int a; int b; a = 3; b = 30; until (a == b) printf("%d\n second ", a); a++; usleep ( 990000 ); printf("\n\n hvala ker usate ta pgr \n\n"); return 0; } [/CODE] but i got this error when … | |
[B]Hello everyone.....[/B] [B]I wanted to know how can we send and receive data from usb port[/B] [B]using c programming[/B]...... | |
Hi, can any one tell me what size_t_count does, i couldnt get it . thanks guyz ! [code] fwrite([COLOR=#0000ff]const[/COLOR] [COLOR=#0000ff]void[/COLOR]*_str,size_t_Size,size_t_count,file *_File); [/code] | |
Hey gang whats up? Here's my problem. Ever since i loaded win xp i have not had any audio through my speakers. i checked the driver in my sound and audio devices and it was installed but not working properly. So i uninstalled it, and downloaded again from the c-media … | |
please help me [url]http://www.linuxforums.org/forum/linux-applications/72657-qt3-designer.html[/url] | |
ok im newbie... i have a question if i have [code] #include <stdio.h> int main() { printf("type something:"); char a; scanf("%c", &a); printf("%c\n" ,a ); return 0; }[/code] i will aways get one character in output.My question is: -how to get world "hello" as standart output from variable using printf? | |
i want to calculate the complexity of the following code snippet [code] for(int k=0;k<n; ++k) for(int j=0; j<k; ++j) for(int i=0; i<j; ++i) cout<< "Hello World" <<endl; [/code] here! i got the hint! that summation of natural numbers series would be used if its correct why ? bit confused:sad: | |
I am doing a lexical analysis program and this is a part of the code that counts number of keywords [code] int keyword=0; char str[]="int float + - 78"; char* ptr; ptr=strtok(str," "); while(ptr!=NULL) { if(((strcmp(ptr,"int"))||(strcmp(ptr,"float")))==0) keyword++; ptr=strtok(NULL," "); } cout<<keyword; [/code] to my knowledge there is no imbalance of … ![]() | |
hi iface aproblem in c program i want to write aprogram to read R={(1,2),(2,1),(3,3),......} then covert it to matrix0/1 please help me quickly ![]() | |
i need a program urgently for round robin schedulng algorithm using circular linked list implementation.. please send a program using c++... post the prg to my mail id.. << moderator edit: removed email address >> | |
There is an algorithm in the software program that other team handed to me on linux. Given a set of requirements, our task is to create a test script/driver to verify that algorithm using a separate data file and spit out the result on the output file. The concept is … | |
Hi all I'm looking forward to purchase ExeCryptor ([url]www.strongbit.com[/url]) to protect my shareware. But before I'd like to know independent opinions/experience if any. My question is: Anybody uses execryptor? Can you tell me smth about? Are there some problems? Is it cost-effective? Thank you in advance for any reply Jean | |
I am new at this but I think I may have it. This is the assignment: The program should ask for the Customers First Name and Last Name (Use Initials only for now) -Use 2 different variables, one for the first name and one for the last The program should … | |
| |
I keep on getting the erro "error C2064: term does not evaluate to a function taking 1 arguments" I have three of these errors and they are all on the first line after the if statements. I really dont know what is going wrong. Been working on this error for … | |
Hello...I need to write a program where i need to copy each word of a string into an array... Eg(string s="hello how are you" arr[0]=hello,arr[1]=how....). any help:?: ?? | |
Hi, Anyone here can advise me correction of my c programming? It doesn't seem to be working. #include<stdio.h> float x[4] = {1.2,2.4,3.6,4.8}; float f[4] = {0.1,0.2,0.3,0.4}; float xave = 0.0; float ftotal = 0.0; main() { int i; for (i=0; 1<4;i++) ftotal + = f[i]; if(ftotal!=1.0) { printf("error\n"); exit(); } … | |
Hey guys, I'm new to C- I do Java- and for our OS class we're doing some basic code examples in C, on Linux. (Fedora core, if it matters). We're supposed to write a test program that shows the difference between how threads are run with round robin and fifo … | |
The question is :Write a function bigger() that returns bigger vaule in a signed integer array. Array and size are passed as arugements. Write a main program that inputs Max values from the keyboard into siged integer array,array and prints using biggest(), the biggest vaule to the screen What should … | |
[COLOR=seagreen]hi, i didn't get any reply probably coz ya didn't understand what i mean ![/COLOR] [COLOR=seagreen]alright i'll make it simple.[/COLOR] [COLOR=seagreen]i have a file in excel and i have to read from this file [/COLOR] [COLOR=seagreen]here is the contents of this file[/COLOR] [TEX] [COLOR=seagreen]2,joined,2929828,429.6,2[/COLOR] [COLOR=seagreen]4,toytoy,2929299,122.8,19[/COLOR] [COLOR=seagreen]3,front shift,2299229,205,22[/COLOR] [COLOR=seagreen]3,shift,1111111,222,20[/COLOR] [COLOR=seagreen]...[/COLOR] [COLOR=seagreen]...[/COLOR] … | |
i want to add all the inserted linked list by using this code but what happens here if i input 15 then 35 =50 but when i input again 30 the sum is 50whats wrong with my code? [CODE] int sum(nd **head){ nd *p,*sum1; p=*head; sum1=0; while(p!=NULL) { sum1->x=p->x; p=p->next; … | |
Hi all, I'd posted this problem previously but in the wrong place..:)..Hopefully, I can get the answer from this thread. I'm a newbie in C..Right now, I have to write a code to read a text file and then insert all the info inside that text file into database. Should … | |
Hello, can you guyz help write a while loop to read this line, for example 2,Joind,2082421,235.6,8 2= number Joind = item 2082421 = item number 235.6 = item price 8 = day all what i'm tryin to do is while reading each line if we encounter a ',' store all … | |
I have got this question: Write function of f(x) that return the number of bits set to 1 in an unsigned integer. So the outcome of the result will be sometime like f(5) = 2 cos [5 in binary is 101 and it got 2 '1s') Here's my program: #include … | |
how to pass a string as an argument to a sub fuction and what is the maximum limit of subscripts that the character array can hold as an argument in a function... | |
Can anyone help me...i have a file modt.txt and i want to save the content in modt2.txt but it seems my code is not working. Moreover, if i have the content of the 1st file Have a nice day. i want to save it to the 2nd file without double … | |
I have a homework assignment that requires that I sort an array of Accounts that contains strings for ID, PIN, and balance. I believe that I need to sort the array based on the ID. And then I have to verify the ID that the user inputs to the accounts … | |
Hi, I have got this question: Write function of bitcount() that return the number of bits set to 1 in an unsigned integer. Here's my try: #include <stdio.h> int bitcount(unsigned x) main() { int b; for (B=0; x!=0; x >>=1) if (x &01) btt return b; } When i compile, … | |
May i know how to write this program. Write a function bigger() that returns bigger vaule in a signed integer array. Array and size are passed as arugements. Write a main program that inputs Max values from the keyboard into siged integer array,array and prints using biggest(), the biggest vaule … | |
attached is the q of the c program....and here's what i try to write out... may i know how should i write to prompt user to enter the four weights from the keyboard. and the program should print an error message if the weights are out of range? Here's my … | |
hello guys i am new in this forum and in programing i want to write a program which could convert given temperature and its unit into oher scales please give me some sugestions and ideas bout that and i need to know how to declear chareters and how to take … | |
i ve got this #include <stdio.h> #include <math.h> void main() { int angle_degree; double angle_radian, pi, value; printf ("\nCompute a table of the sine function\n\n"); pi = 4.0*atan(1.0); printf ( " Value of PI = %f \n\n", pi ); printf ( " angle Sine \n" ); angle_degree=0; while ( angle_degree … | |
Im a student at YSU in Youngstown, Ohio and I'm taking a computer programming and problem solving class. I'm lost completely and I have this assignment that was given to me that I have no clue at all what to do. My question to you is could you please help … | |
#include "stdafx.h" #include <stdio.h> #include<stdlib.h> #include<iostream> typedef struct Sale { int clientNumber[4]; char Item[45]; char PartNum[12]; int UniCost[11]; char DayOfMonth[20]; }; Sale rSale[197]; typedef struct Data { int clientNumber[4]; char Company[34]; char ABN[14]; char StreetName[36]; char Suburb[24]; char State[11]; char PostCode[5]; char Phone[15]; }; Data rData[10]; int _tmain(int argc, _TCHAR* … | |
Hi folks. I'm new to the board and I sincerely apologize if this has been posted time and again. I did search but couldn't find an answer. I am starting to program for the Symbian OS (never done it before) and have Visual Studio 2005 at my disposal. I've read … | |
hi i have a function that opens a file and store the data into a matrix [CODE]void openfile(vector<vector<string> >& data, string path) { ifstream inFile; inFile.open(path); ....[/CODE] this does not work but it works when i eliminate the path as input [CODE]void openfile(vector<vector<string> >& data) { ifstream inFile; inFile.open("C:\file.csv"); ....[/CODE] … | |
about ComboBox problem <<<<<<<Dialog.h>>>>>>>> public: CComboBox Cbx; struct Data { LPCTSTR lpszName; LPCTSTR lpszValue; int ID; }; <<<<<<<Dialog.Cpp>>>>>>> Data d; d.lpszName=_T("Name"); d.lpszValue=_T("Value"); d.ID=1; Cbx.InsertString(0,d.lpszName); Cbx.SetItemDataPtr(0,(void *)d); how to struct data append to ComboBox Control,thank:) | |
Can I know something about Sequential Search?? Answers within 24 Hours PlZ.. | |
Please provide me some sample programs that illustrates sorting techniques and about Sequential Search also.. | |
I have a homework assignment to write a program about mileage. I've been able to get it to work, well except the average doesn't calculate correctly and I haven't been able to verifiy the users input. I'm using Visual C as my compiler. Can someone help me with checking the … | |
When I compiled the follwing code snippet, it compiled without any error. My question is if it is allowed to declare [I]char[/I] fields inside a structure, then how can I store character string in that variable(we can not use functoins like strcpy:-| ). OR Is it not allowed to declare … | |
I get the following error on the first line of my array... " syntax error before `}' token " My eyes are about to fall out of my skull. Can someone take a look for me, everything seems to be fine, but maybe I'm blind. Here is the code in … | |
[B]i want to find out small projects to work upon so as to improve my grip over c, can someone tell me some sites having projects in c:confused: [/B] | |
hello i want a programming concept in c in which it should take a query of sql and regarding table and then give the output as a resulting instance corresponding to query | |
I am completing my degree in Multimedia and Software Developement. The two languages that are being focused on are VB.net and Java. When I finish my degree, I will have not had a class in C++. Is C++ not used very much any more? I was just kind of curious. ![]() | |
#include <stdio.h> #include <string.h> char* string(char *str); int main() { printf("%s\n ",string(" in this method ")); getchar(); return 0; } char *string(char *str4) { char str[25] = "How"; char str2[25] = " do I "; char str3[25] = " return a string"; strcat(str,str2); //append str2 to str and return str … |
The End.