49,760 Topics

Member Avatar for
Member Avatar for necrolin

My C++ course hasn't covered a topic yet, but I'm expected to solve a few problems with this material. I've got some working code I just don't fully understand it. Can someone help me, please? [CODE] void f(int** a) //What is this ** business? (1) { cout << **a; //prints …

Member Avatar for dkalita
0
88
Member Avatar for Tajna

hello ! I`m trying to use sqlite database with c++, but something isnt working right... The problem I`m dealing here is that i cant insert other datas into the table i`ve created except NULL, because i get following error message: Error in select statement : INSERT INTO a (a,b,c,d) VALUES …

Member Avatar for Tajna
0
100
Member Avatar for restrictment

The question is in the title. I am trying to make an image that includes this character... *typo in title. It should say 'do', not 'to'.*

Member Avatar for jbennet
0
855
Member Avatar for mymyzzz

how do i get int in fstream? i am in need to change my char to int. i am not allowed to use anything above and including fuctions. this includes sstream. is there any way for the program to read "3" in the program as an interger?

Member Avatar for pecet
0
156
Member Avatar for mymyzzz

i need to know how many times the while loop is done. while (myin) { myin >> name; cout << name ; myin >> num1 >> num2 >> num3; cout << " " << fixed << setprecision(0)<< num1 << " "<< num2 << " "<< num3 ; average = (num1 …

Member Avatar for nambro
0
81
Member Avatar for GPXtC02

what i have so far - [code]void do_handleclient(int connsock,struct sockaddr_in *client_addr) { // Communicating with our new friend. string buffer, execmd, filename; int b, n, nstr, str; char buf[25000]; char *cbuff=(char*)buf.c_str(); while((n=recv(connsock,buf,25000-1,0))!=0) //receiving request. buffer[n]=0; while(buffer[nstr]!=' ') { //pulling GET or POST command out of request. execmd[nstr]=buffer[nstr]; nstr++; } while(buffer[nstr]!='\r' …

Member Avatar for dkalita
0
116
Member Avatar for rrvs331

So I have a coin flipping program that ouputs all results to a txt file. I was wondering how would i search the results so that I could pick out things like how many times a specific result was repeated in a row. For example if the results were Heads …

Member Avatar for Clinton Portis
0
75
Member Avatar for mymyzzz

CSCI 1170: Open Lab Assignment #5 Program due: Thursday, Oct 29, 2009 at midnight as the day turns to Friday Oct 30, 2009. Professor: c8296800 code: ola5 Purpose of this assignment: The purpose of this assignment is to understand the while loop programming construct. This assignment will let you 1. …

Member Avatar for Clinton Portis
0
159
Member Avatar for jojojijijojo

Hello everyone, I'm new here and I'm looking for some help because I'm a beginner at c++, and I'm learning right now, I got a problem that i don't know how to solve, Here is the problem: Suppose we have 10 lines in a file and 4 input values in …

Member Avatar for Clinton Portis
0
96
Member Avatar for lotrsimp12345

Error 1 error LNK2019: unresolved external symbol "public: __thiscall vector::my_vector<int>::~my_vector<int>(void)" (??1?$my_vector@H@vector@@QAE@XZ) referenced in function _main test.obj Error 2 error LNK2019: unresolved external symbol "public: __thiscall vector::my_vector<int>::my_vector<int>(void)" (??0?$my_vector@H@vector@@QAE@XZ) referenced in function _main test.obj Error 3 fatal error LNK1120: 2 unresolved externals C:\Users\...\Documents\Visual Studio 2008\Projects\Iterator and Generic Vector Container\Debug\Iterator and Generic Vector …

Member Avatar for Dave Sinkula
0
142
Member Avatar for dylank

Hi, I have posted in a previous thread about this problem, but this seems not related enough to post in it. My problem is with this code: [code]//This is VERY simple, will just graph a y=mx+b type formula into 2 arrays. #include <iostream> using namespace std; int main() { //Counters …

Member Avatar for Clinton Portis
0
116
Member Avatar for mymyzzz

i got to do this for my class and i am a total noob! i don't know what to do from this point on. first, i need to use fstream to do this. 3 Tracy 80 91 67 Dana 0 66 44 Scott 50 41 64 Jamie 82 90 87 …

Member Avatar for Clinton Portis
0
288
Member Avatar for mymyzzz

i have this Tracy 80 91 67 and it is read from a file, making it fstream. i want the computer to reconize the numbers and add them and divide them, excluding the name. how do i do it? i can't use fuction so please make it easy.

Member Avatar for mrnutty
0
105
Member Avatar for cjf90

Alright, I have an assignment in which I have to use ANSI Escape Sequences to colorize output on the console. So "\033[0;31m" colorizes text after it to be red for example. When I run the following: [code]cout << "\033[0;31mhello \033[0;37mworld";[/code] It works as it is supposed to, with "hello" printing …

Member Avatar for cjf90
0
116
Member Avatar for Niner710

Hi, I am trying to understand the concept of clone with respect to making a deep copy of an object. The class Bmapfile is an abstract class in which other subclasses will inherit from. I am not sure what to put into the doObjCopy function in Class BaseClass. I want …

0
90
Member Avatar for srinwantudey

Hi, I am very new to C++ programming. I need to do some work urgenty..... I have a video file with some conversation going on... I need to extract the speech transcript (possibly in a text file) Please help me seniors and give me some ideas...

0
46
Member Avatar for bunnyboy

So I would like to make a function which would add elements in container in sorted manner. Let's say we have a struct with two integer. I randomly initialize them and the add it to deque. And now what I want is that my function would add them in a …

Member Avatar for Clinton Portis
0
134
Member Avatar for nightninja12

i have a project for my programming class where we have to create a binary search tree and then when the program exits we need to save the tree to a text file and then restore it when the program opens. the basic functions were given to us, but the …

Member Avatar for Lerner
0
158
Member Avatar for reese27

I'm trying to figure out how to even start a program that removes suffixes like if i were to enter programs, are, not, limited, to, drawing, composition, it would output.... program are not limit to draw composi

Member Avatar for Lerner
0
113
Member Avatar for johndoe444

Hi, My knowledge of c++ is limited to basic syntax used in basic programming assignment while I have some years of software development experience (particularly web application) using java. I have not created any thing big in c++ ever. Now coming back to c++ at present, I am confused how …

Member Avatar for johndoe444
0
123
Member Avatar for jmoran19

Hi, hope someone can help with an issue I'm having. Basically, I've got an input file containing, amongst other things, an int on each line representing a time stamp in the form of hhmmss. I needed to make a comparison from line to line to make sure that no more …

Member Avatar for jmoran19
0
100
Member Avatar for Lukezzz

I am trying to do a function that is a textBox contains 2 dots (.) then the last dot(.) will be deleted, so it wont be possible to write 2 dots(.) in this textbox. When I write the second dot in this textBox, then also the first is deleted, for …

Member Avatar for jonsca
0
101
Member Avatar for surfer2009

some of the characteristics of a book are title,author,publiser,ISBN,price and year of publication.design a class booktype . 1) each object of the class booktype can hold the following information about a book:title upto four authors,publisher,ISBN,price and number copies in stock. To keep track of the number of authors ,add another …

-2
70
Member Avatar for lancevo3

Hey guys I am trying to print the contents of a map container I have. I seem to be getting a nasty error from the compiler which seems to come from the pos = wordList.begin() part. any suggestions? [code=cplusplus] map<string, unsigned>::iterator pos; for(pos = wordList.begin(); pos != wordList.end(); ++pos) { …

Member Avatar for twomers
0
507
Member Avatar for joelol

[CODE]#include "stdafx.h" #include <iostream> #include <string> // say what standard-library names we use using std::cin; using std::cout; using std::endl; using std::string; int main() { // ask for the person's name cout << "What's your name? "; // read the name string name; cin >> name; // build the message that …

Member Avatar for wingless
0
86
Member Avatar for Star Frost

I know this might seem like a repeat of an already existent thread, however give me a moment to explain... What I have so far is a function that reads in a script file and stores each word in an array of custom objects. function: [CODE] void fileTester::readFile( string tempName …

Member Avatar for Star Frost
0
185
Member Avatar for snapppy

Hi, was wondering if anyone could put this simple pseudo code into c++, i have not yet learned the code to do it and dont want to wait. If someone could post it i would appreiciate it a lot, thanks! BEGIN Enter # Clear Screen Count = 0; WHILE (Count …

Member Avatar for Grn Xtrm
0
205
Member Avatar for parasm

how to deallocate memory in a c++ program dynamically without using destructor?plz help me.

Member Avatar for sfuo
0
40
Member Avatar for discovery-power

Hi All, I have written a small interactive console application to help me understand variables, when you run the application it will ask you for a length and a width and it is supposed to work out the area. It works up to the part were it is supposed to …

Member Avatar for discovery-power
0
94
Member Avatar for Bips123

Hi, I hav heard that it isn't that simple to write a program in linux using c. Lots of commands n stuff.Please simplify what actually I've got to do to run turbo c++ in my linux laptop as I am a beginner.

Member Avatar for Ancient Dragon
0
137

The End.