General C++ Programming - March 2012 (Page 36)

Series Return values
 
I am trying to return the values for the terms of an arithmetic series. However, I am having difficulties in establishing the orientation of each "terms'" sign...
[1 reply] : Hi which arithmetic series is it ? and what kind of difficulties " in... (by therockon7throw)
assignment help
 
this assignment is using polymorphism and inheritance. Requirements: 1. The “is a” relationship is modeled by public inheritance. 2. The “has a” re...
[1 reply] : Hi I think the calculate_area() method should be a pure virtual m... (by therockon7throw)
'string' does not name a type
 
HELP! i'm getting what seems like an erroneous error! i've got #include <string> in the top of my .cpp, but i keep getting the error 'string' does not name a t...
[8 replies] Last: wow right on the front page... sadly that explains why i didn't see it... (by C Theroux)
Returning a specific value from an array
 
I have to write a modular program that accepts at least 10 integer test scores from the user and stores them in an array. Then main should display how many perf...
[3 replies] Last: I'm a little unsure of whether you need reference arguments or not dur... (by KeisterBun)
file pointer, positioning from end
 
Hi - I need to write a utility that will extract values from the last 256 lines of a large file. Each line will look like this: NN XXXXXXXX XXXXXXXX ...
[7 replies] Last: std::deque<char> txt; std::ifstream f ("file.txt", ios::in|ios::ate/*... (by LB)
Sorting Names Alphabetically!! Help!!!
 
Hi! I'm writing a program in C++ where the user is asked to enter a list of ten names and cities of residence in the format <firstname> <Surname> <city>. ...
[3 replies] Last: alternatively, you could also use strcmp on any two char array string... (by SIK)
Converting words to numbers
 
Hello! I need help on a program that I'm making. I already spent a lot of days for this but i just can't figure it out. The program that I'm trying to make is C...
[1 reply] : Suppose you store your worded number in a string called strInput. Y... (by SIK)
how to sort IP addresses in routing table in C++?
 
how to sort IP addresses in routing table in ascending order in C or C++? like if we've two same ip addreses, 128.0.0.0 with prefix length 2 and 128.0.0.0 with ...
[1 reply] : If you are using Windows perhaps start here: http://msdn.microsoft.com... (by Texan40)
by alan G
String to Char
 
Hello, I am new to programing and I have this home work assignment that I need help solving. :) What I need my program to do is convert user input into all ...
[5 replies] Last: Transform is explained pretty well here: http://www.cplusplus.com/refe... (by Computergeek01)
wrong output
 
Hello I wrote a program that converts a binary value to a dec number But it converts wrong: input : 1111100 output:31 but 31 decimal is 0011111 binar...
[5 replies] Last: thanks :) (by closed account 4w7X92yv)
summation
 
Hello Can you do a summation in c++? I have to calculate a binary number to a decimal number using IEEE 754 single precision If there is a funcion, where...
[3 replies] Last: You can use bitset http://www.cplusplus.com/reference/stl/bitset/bitse... (by closed account o1vk4iN6)
by sebas
Size of multidimentional array
 
Hi there!. I am performing some calculations with matrices but it happens that I have a lack of RAM memory. I know how to calculate the memory allocated for a...
[4 replies] Last: Hi Under Windows you can get the total avaliable memory by MEMORY... (by therockon7throw)
Linking errors
 
Here are the errors: InputTest.obj : error LNK2019: unresolved external symbol "int __cdecl copyarray<char>(char * const,int)" (??$copyarray@D@@YAHQADH@Z) ref...
[6 replies] Last: No, you have it like this, and it's not correct: whatever.h: temp... (by ciphermagi)
What's wrong with this line?
 
There's this one line of code that's giving me trouble and I can't seem to figure out what I'm doing wrong. Any suggestions? if(tok2.value.at(0) == '(' )...
[4 replies] Last: You could do something like this this: #include <algorithm> //... i... (by clanmjc)
malloc() memory corruption
 
Hi to all!!.. I have a problem sometimes in this function.. int readStopList(FILE *stopFile, char ***stopList) { int w; char wrd ; // #define MAX_...
[2 replies] Last: Hi my friend vlad from moscow... That seems to have solved the problem... (by MacGregor)
Need to recognise Enter as a character
 
Hey guys, So I have the following part of my function which changes the entries of some members in my struct: cout << "Enter new status (existing: " <<...
[4 replies] Last: void edit(int entryNumber, int numberOfEntries) { char in ; //Cl... (by Lachlan Chartier)
Error: Undefined Reference to WinMain@16
 
Hi! I'm writing a program in C++ to ask the user for a list of ten names and cities of residence in the format <firstname> <Surname> <city>. I am using is...
[8 replies] Last: Any ideas on how I can use this code to write the program I need to wr... (by ProgrammerGRM)
Missing function header. (old-style formal list?)
 
#include <iostream> #include <time.h> #include <windows.h> using namespace std; int main(); { //1 //variable declaration char board = ...
[6 replies] Last: its working now! thank you so much!!! (by kristine inah villanueva)
by LB
Polymorphism, Clone Pattern, Confusion++
 
#include <iostream> template<typename T> struct Cloneable { virtual T *Clone() const { return new T(*dynamic_cast<const T*>(this)); } protected: Cloneab...
[8 replies] Last: Well, I read about using the templated clone class to auto-implement t... (by LB)
by Odin13
Quadratic equation solver
 
Hi I'm making a program so that it solves quadratic equations (ax^2 + bx + c), bu it doesn't give me any response... I wrote this: #include <iostream> ...
[3 replies] Last: Thank you for your help, it works perfectly now!! (by Odin13)
March 2012 Pages: 1... 3435363738... 49
  Archived months: [feb2012] [apr2012]

This is an archived page. To post a new message, go to the current page.