18,490 Topics
H! plz solve a problem..............! See I want to take continuous four input from the user, out of which three are character type and one is of int type. So my problem actually is that, it accepts only three input i.e. 2 char and one int & for remaining char …
sorry about my english i make a game and i need to use on interrupt i/o(input), someone can to help me?? the code is : [ICODE] cout<<"Enter num : "; for(i=1; i<=100000000; i++){//its loop time // here the interrupt // when the user click some key its //stop the loop …
Here is a data file like this,please help me update my code to omit all comments stored in the file.sample file looks like this: C:\\s1.txt #author:Single Ray #data:02-2-10 141.641, 567.614, 24.25 140.939, 567.736, 24.25 #start 140.053, 567.947, 24.25 148.985, 568.352, 24.25 #end .... Im sorry,forgot attach my codes,here is my …
Hello C program Gurus... i have problem with my programming. i can run my prog but its something not right... my prog is to make an automated reservation system program to assign seats on flight of the plane that have apacity 10 seats. the program should display the following menu …
Hi I wrote that peace of code but it is not doing what is suppose to do. It should saved my numbers into linked lists in incresing order. It doesn't. What am I missing. Thanks [CODE]#include<stdio.h> #include<conio.h> struct Node { int number; struct Node *link; }; typedef struct Node* NodePtr; …
Hello all, im new to this community and i would use some help. I have learned VB.Net and i write programms for almost a year and a half. Currently im learning C, C++, and C#, but i dont have any expirience with these languages. So i would like you to …
Hi, I am have trouble in Array of pointers to structure. I have defined as structure. typedef struct { char * name[5]; int number; }mystr; I have defined an array of pointers to this structure.( is this correct ?) mystr (* myptr)[5]; To fill the values, i have to pass …
hello there! im creating a program with both stdio.h and iostream.h in the include header. Can the program run with them both? or others?
Hi I want to read a two huge integer input from user & wanted to display output on the screen can any one help me ? eg : int a=8132123781237; int b=1237829789; result = a *b ; print(result); ????
Howdy folks, Does anyone know if GCC is capable of creating a fixed length 1D array of an N-Dimensional array for reasons of speed? I've heard it matters quite a lot if one works constantly with N-Dimensional (with N != 1) compared to 1D arrays in terms of speed, but …
I've been trying to find a complete list of the c/c++ libraries and all of their functions, but everywhere I look, I only find a part, never the whole thing. Is there a website where I can find such detailed list?
H all, I am intersted to do home based freelance programing work. Can anybody give me some idea of which areas of prgramming ( e.g C, C++, assembly, Java, device drivers, web development, database...etc) are the most rewarding and what are the payments rates being offered ? I visited elance …
Well, I think I've just had my worst programming gaffe. I write a 600 line program using linked lists and compile it. In addition to the usual missing ";" and "}", I continuously kept getting a "x not declared" error whenever I tried to access a variable from a pointer …
Hi, i've a problem about load and parse a large array block on my dictionary-like app. My app will load mytext.db to its array. App users entered specific text to txtIn, press cmdSearch and get the translated ones. The main issue is scanning speed, load array speed and match input …
Some numbers like 1,2,3,4,.... are provided from the command line. Considering them to be roots of a polynomial of that degree< equal to number of roots > , i was trying to find the coefficients of the constructed polynomial, i was using the concept of multiplication of two single degree …
run it type hello, press enter then type end in a c ompiler [CODE=c]#include <stdio.h> #include "strlib.h" #include "simpio.h" #include "genlib.h" #include "string.h" #define size 50 void reverse(char rev[]); int main() { char rev[size], i; printf("Please enter a sentence and end the sentence with a enter than end \n"); reverse(rev); …
hallo! ppl plz help me write the pseudocode for the following problem! im new at this and have no clue how to do it! the assignment is due tmrw so quick help will b appreciated 1) enter 55 test scores and print how many were passing scores(50 or more)and how …
i am new to assembly programming,can anybody help me out to solve this problem - i have a assembly code which does the atomic increment [code=assembly] Atomic_Add (volatile unsigned int *addr, int additive) { register unsigned int previous; __asm__ volatile ( "pushf;" "cli;" "movl (%2), %0;" /* previous = *addr; …
it is known that dennis rithie made c with only 32 keywords and writing functions is the responsibility of the programmer. who wrote the functions printf, scanf . what is it's sourcr code?
Hey....Help me in this one please... I have to encode something that the output will come out as example....10, 8, 6, 4, 2, 0..... please help me what I did wrong....Thanks ...and I like to thank Narue too...for helping me in my last problem....I have to do this without using …
I found the following code in the 'Code snippets' section( written by nanodano). i tried compiling it in my Dev-Cpp compiler, and i got the output as shown in the attachment for up, left, down and right arrow keys respectively. All other defined keys i.e., F1 to F10 gave the …
please help with this program i dont know whats wrong. [CODE]#include <stdio.h> #include "strlib.h" #include "simpio.h" #include "genlib.h" #include "string.h" void reverse(void); int main() { printf("Please enter a sentence and end the sentence with a -\n"); reverse(); system("Pause"); } void reverse(void) { int ch; if(getchar(ch) != EOF) { reverse(); putchar(ch); …
Hello there! I wrote a small program in C on Windows using DevC++. It works perfectly, but when I try to run it on Linux I get compiler erros at these lines: [code=c]void printOctets(int octets[][], char []); void printInterval(int suntwk[][], int brdc[][]); [/code] This is a college assignment and I'm …
Hi there. I do not understand the following line of code. [ICODE] program_counter = (memory[0xFFFD] << 8) | memory[0xFFFC]; [/ICODE] [QUOTE] The array memory[] represents the memory space of our processor. The starting address for a 6502 program is stored at location $FFFC and $FFFD in memory. The 6502 stores …
[code=c] #include<stdio.h> #include<stdlib.h> main() { char a[32],*a1,b[64],*b1; a1=&a[0]; b1=&b[0]; a1="hellohellohellohellohellohello" ; printf("\n contents of a1: %s\n",a1); int i =0; for(i=0;i<=31;i++) { printf("%c",a[i]); } } [/code] So why does printf ("%s",a1) work correctly while printf("%c",a[i]) display junk ? Since a1 points to a[0], shouldn'it it display the same values ?
hi guys, I have a simple question and I am new to c, Would appreciate any advise I could get. Here's the doubt. [code=c] main() { char a[10],*a1,b[10],*b1; a1=&a[0]; b1=&b[0]; int x=0; for (x=0;x<=1-;x++0) { *a1++=*b1++; } } [/code] Basically if I had a string in b[10] it would get …
Hi, Can you plz help me in creating a file in C having columns rec_id (int), score (float), hour (int), no_clicks (int) with rec_id values ranging from 1 to 100, score values initialized to 0.11, hour values initialized to 0 and no_clicks values also initialized to 0. And then generating …
how can you make program using a linked list that displays your outputs in ascending alphabetical order? we are only allowed to use: #include<stdio.h> #include<conio.h> #include<stdlib.h> #include<string.h> TIA
hai ia have been try this but i didnt get any output on my run window. #include<process.h> main() { system("echo hello"); } [B] consider me[/B]
Pete here. I'm more of a hardware guy than software -- Just coming up on 20 years of digital and mixed-signal integrated circuit design. I know how to write hardware description language code, I've written just enough C to be truly dangerous, and I work on a Linux system in …
Hi have a problem, this code should read a file and then save it in a linked list, just the <uid><name> from a lie looking like: <username>:<password>:<uid>:<gid>:<fullname>:<home dir>:<shell> I can't find the segmentation fault error atm, but hints on the code would be helpfull. Atfer the insert in user list …
How long did it take you to learn C++ or C or VB. I learning some what C for my Linux class.
Hey everyone, I am supposed to write a program that counts the number of vowels in string of characters. It must include "Struct counter_t (it must be declared as in the code i've written)" and function "int CountVowels (IN text[], OUT Count)". the OUT parameter must be of type counter_t. …
Hi!!! This is my first time to post here and I have a problem and I want your help..... This is the case my teacher gave me a question to add 1 to 100 using while loop and its really confusing me... but here is my idea and I jsut …
[CODE=C]#include<stdio.h> #include<conio.h> int main() { float a=0.7; if(a<0.7) printf("C"); else printf("C++"); getch(); return 0; }[/CODE] The above code prints 'C'. Whereas the following two codes prints 'C++'. Why is that? [CODE=C]#include<stdio.h> #include<conio.h> int main() { float a=0.7; if(a>0.7) printf("C"); else printf("C++"); getch(); return 0; }[/CODE] [CODE=C]#include<stdio.h> #include<conio.h> int main() { …
Hi! I'm just having a problem in displaying strings of line in the command prompt. My program is to search a string and enclose it with three asterisks both sides. Though it's functioning... But the problem is the program show only those lines where the strings are present. Thr program …
Hi All, Please help with the below Valet Parking Problem. Let me know if you need more info. The valet parking problem: Some fancy restaurants (i.e. ones without a drive-through window) offer a valet parking service with which one of the restaurant's employees will park your car for you as …
Hi! My code is to search for the strings. Example when you type srtool.exe -s in -f sample.txt (in the command prompt), all the words containing "in" will be changed to ***in*** My problem is all words containing in will change to ** (one asterisk per word) instead of ***in*** …
I'm a web designer and am looking to get into programming. I have zero experience with programming. I think the best place to start is with C (open to suggestions) and last night purchased the K&R book on C. I almost exclusively use a Mac (OS X 10.4 - Tiger) …
I am very confused how to write a function which can accept 3 input parameter to calculate sum and average.the sum and average should be returned through output parameter ... pls help ..thx
hi, I am developing an application in Windows CE platform is Windows Ce .net 4.2. i need to play media file through C code, i have managed to play media file in win32 through "system" command but this command is not available for Windows CE, i have tried CreateProcess function …
hi all, I want to convert a string contain hex format '0x15' and what to convert it integer because i want to write data contain by a integer variable in hex format (binary data) into the file. here is my code [code=c] char * str = "0x15"; int value; FILE …
Basicly i tried to do address book but i guest it not work at all..can i know where i get wrong or any advise?..
How to create an initialised list and delete any node from the list using C language.Please help me.I need it urgently.
good day, i rily nid help on something.... its about gotoxy in turbo c... 1st of all, can u use gotoxy in turbo c? (c++ 6.0) 2nd, if u can... can i ask how to use it? please help me... im just a beginner... lol.... h0pe u c0uld help me... …
Hi All, I need to convert a Assembly Code to high level languages such as C/C++, C#, .Net vs vs. I found a [URL="http://www.microapl.co.uk/asm2c/index.html"]website [/URL]that converts it but with very very high price. I am looking for a simple program which tries to convert assembly to high level language. I …
hi all i want the code for reversing a string eg : I live in india Ans India in live i
OpenWatcom has a very nice feature in its C language which allows you to code assembly language procedures/functions that you can pass parameters to, receive return values and whose register usage is integrated into the C code optimization. Compare this with the classic MS construct `_asm` and `_asm {}` which …
hi, I am developing an application in Windows CE platform is Windows Ce .net 4.2. i need to play media file through C code, i have managed to play media file in win32 through "system" command but this command is not available for Windows CE, i have tried CreateProcess function …
Hello everyone, I don't know what is the exact name to call this, so I call based on what I want to do in my program. Its operation got something similar to chat server and client. I have server and client application. Firstly, when one client connects to server and …
The End.