49,761 Topics

Member Avatar for
Member Avatar for mikecoyner

i teach a high school c++ course. i would like to use a window for user interface instead of dos console. could anyone provide me the basic code to display "hello world" in a window? and if possible a link to the code necessary to use window api for c++ …

Member Avatar for Narue
0
209
Member Avatar for camduthie

I am trying to write a phonebook program that uses a dat file to store the numbers (ex. in dat file--John Doe 5554445555). I have it to the point when the user keys "John" in, it will display the number. If the user keys in "John Doe", it will not …

Member Avatar for Narue
0
109
Member Avatar for ecua_frap

hi.. i'm pretty new with C++, so pls. bear with my question, simple as it may be. can anyone pls. tell me what this error mean: [I]syntax error before `<'[/I] i have a whole bunch of them when i try to compile.. if needed, i'll post up the codes. Thanks!

Member Avatar for kc0arf
0
125
Member Avatar for jhammer

I am wondering if someone could tell me what tools I will need to compile and build and executable of Dev-C++ for Fedora Core 3 to install it and run it. I have never worked with Delphi source code and I would appreciate any help with the process and what …

Member Avatar for jhammer
0
170
Member Avatar for Mr Violent

I'm currently writing a game in DirectX without using the MFC structure. I am manually crating the window by including windows.h and manually creating the window by using windows functions. I am a bit confused when it comes to using strings. I would like to use the CString class, as …

Member Avatar for Narue
0
482
Member Avatar for jonnie83

The following code is not performing correctly. It opens the username file but does not display the mark. [code]#include <cstdlib> //these commands are pre processors directive #include <fstream> //required for library function #include <iostream> #include <cstring> #include <string> using namespace std; int main() { cout << "Marking Program"<<endl; string username; …

Member Avatar for Narue
0
215
Member Avatar for some one

Write program that reads some information of 10 students (name [max 15] , level number , #of points , #of hours , GPA , student id ). These fields should be filled for each student by user except GPA. The GPA (max: 5) should be calculate it by function that …

Member Avatar for Narue
0
205
Member Avatar for some one

[SIZE=4][COLOR=DimGray]please I need your help inthis program because I do not under stand what does he want and I didn't under stand the array so please help me[/SIZE][/COLOR] Write a function named "eliminate_duplicates" that takes an array of integers in random order and eliminates all the duplicate integers in the …

Member Avatar for some one
0
501
Member Avatar for jonnie83

The following program executes without any errors, but the output is not what is expected. The code is correct down till the opening of the MarkScheme.txt file, but the student mark is not displayed on the screen, any thoughts [code]#include <cstdlib> #include <fstream> #include <iostream> #include <cstring> #include <string> using …

Member Avatar for Narue
0
166
Member Avatar for banbangou

Anybody could tell me what's wrong with the following code? It complaints: 13 C:\apps\Dev-Cpp\projects\14\14_1.cpp ISO C++ forbids defining types within return type Thanks in advance. [code]#include <iostream> #include <cstdlib> using namespace std; struct vector { double x; double y; friend ostream& operator<< (ostream&, vector); } ostream& operator<< (ostream& o, vector …

Member Avatar for quickhelp
0
177
Member Avatar for Starz20

Hello everyone. My instructor has asked me to write a program that accepts a string as input from a user and prints the string in reverse. I have to use a "for" loop to reverse the string. I am also suppose to allow the user to input more than one …

Member Avatar for Narue
0
164
Member Avatar for Starz20

Hi, everyone. You may have probably heard this a hundred times, but I am new to programming and I am taking an intro to C++ class. I have a program that I have written, but I can't understand why it will not exit gracefully. This is what I have written, …

Member Avatar for Starz20
0
161
Member Avatar for some one

please where is the error in this code doesn't run [code] #include<iostream> #include<cstdlib> using namespace std; int main() { int ages[1000]; int size=1000; int i,a,b; for( i=0;i<size;i++) { ages[i]=rand(); for( a=1;a<size;a++) { for( b=size-1;b>=a;b--) { if(ages[b-1]<ages[b]) { i=ages[b-1]; ages[b-1]=ages[i]; ages[b]=i; } } } } cout<<ages[i]; return 0; } [/code] Code …

Member Avatar for some one
0
112
Member Avatar for Acidburn

Hello, as you well know I've got a hangman game produced, I now have the luxury of adding to the code since all my work is completed ...yay, well, I've decieded to take it a step further and draw out the hunged man! I have the drawing , its just …

Member Avatar for Acidburn
0
2K
Member Avatar for hopeolicious

how do I get my calculations like ex. I want to add up the average gallons used per mile for a car if the car went like 1450 miles and used 62 gallons of gas I dont want it to be a whole number i want it to be like …

Member Avatar for Dave Sinkula
0
177
Member Avatar for acidburns

:evil: The following C program is mainly written to work as an address book. I have written the code but the VC++ compiler shows four errors and I cant find them :rolleyes: . Can some one please help me find them..my assignment deadline line is on the 10th of this …

Member Avatar for acidburns
0
177
Member Avatar for mel2005

[U][B]i only want what you think, the anser is, this came in a exam paper last year, am not sure what the answer is, can anyone help and explane what hes after please[/B]Using access and visual basic or c++ or pascal[/U] i've been told something like this will come again, …

Member Avatar for mel2005
0
88
Member Avatar for msaqib

Hello here is a site that contains lot of tutorials for C/C++ programming. Hopefully u will find them useful and also u can download the source code. [url]http://www.mycplus.com/[/url]

Member Avatar for JoBe
0
106
Member Avatar for tyczj

so im trying to write this program that converts Fahrenheit to Celsius and vice versa but im gettin an infinate loop at the menu. i go to select the number that i want and it just displays the menu again, i though i was doin it right? [code]#include <iostream> //for …

Member Avatar for tyczj
0
113
Member Avatar for mel2005

i know this is a vb assignment, but my tutor want me to do it in vb or c++ with access, i need to create tables with access, i can see two tables but am sure there another one, i know css is a table and pencil is also a …

Member Avatar for alc6379
0
131
Member Avatar for itebook

[I]Link removed due to illegal content. If you feel this change was made in error, PM me with proof of legality. -Narue[/I] This site contains 1700+ ebooks on php, Java, access, .NET, c#, UML, Perl, c++, linux, sql server, asp.net, Oracle, db2, xml, javascript, unix, flash, cisco, excel.

0
86
Member Avatar for meabed

This is a short list of recommendations on how to use C++. My experiences are from using gcc 2.8.0 and Visual C++ 6.0. I had to have things compatible between these two compilers, and between Unix and Windows. [b]Contents[/b] [color=#800080]IO of binary files[/color] [color=#800080]When are destructors called for local variables[/color] …

0
137
Member Avatar for lulug76

I am trying to make the random generator fill my array with no duplicates. An diplay the in order but aslo first line to print array[0], then second line array[0] and array[1], so on and so on until it display all twenty on one line. Pease help [code] #include <iostream.h> …

Member Avatar for lulug76
0
166
Member Avatar for bobr_1013

Hi, Ran into another issue with my program. In C or C++ is there an easy way to skip the linefead at the end of a record (hex 0a)? Thanks,

Member Avatar for bobr_1013
0
192
Member Avatar for AaronYoq

I'm trying to get the computer to compare a username and password entered by the user to a username and password in a text file. If a match is found, then I am going to present the user with other options. I think there must be an easier way to …

0
134
Member Avatar for peterb92

hello experts!!! im just a beginer.. thats wants to know alot.. i want to program my own tictactoe game.. but i dont have visual basic..can anybody plz.. give me some codes that i can edit my self with javascript or html.. if possible? can you make a tictactoe game with …

Member Avatar for Narue
0
110
Member Avatar for k0ld

Here is the code: [code] #include <iostream> #include <cstdlib> using namespace std; class student { public: void inputScores(); // Prompts user to enter 2 quiz, a mid term, and a final score; store // them in corresponding data members. void computeGrade(); // Compute average and then convert the average to …

Member Avatar for k0ld
0
191
Member Avatar for missy

i need help to rewrite this in infix to postfix using class. it was in a struct format at first, now i need to format this in a class version. [code] #include <iostream> #include <cstring> using namespace std; const int SIZE = 20; private: int top; char num [SIZE]; public: …

Member Avatar for Narue
0
162
Member Avatar for gracieLou

How do you convert a string to an int? In my book under string functions, it shows this short example: [CODE]ia = atoi ("-123.45xyz"); [/CODE] which says that ia = 123. So, I tried applying this to my code. [CODE] index = atoi (a.GetCode()); cout<<description[index]; //a.GetCode() returns a number string …

Member Avatar for marinme
0
91
Member Avatar for cblue

Can anyone give me an idea how to convert an int or decimal number into hexadecimal? I know how to do it for binary by dividing by 2 and using the modulus % operator, but how do you take into account a b c d e f if the integer …

Member Avatar for Narue
0
151

The End.