49,757 Topics

Member Avatar for
Member Avatar for yongj

Hello, forum :) Does anyone know a c++ code that performs the same actions as a "tee" command does in linux? Basically what the tee command does is read an input from an input stream and directs it to two places: 1) Displays the input stream on the screen 2) …

Member Avatar for yongj
0
1K
Member Avatar for Nandomo

Okay. I have a program I am writing similar to the lottery, my input file provides 10 combinations and my rand() produces 5 random numbers which I want to compare them against using binary and linear search. I know how to compare them 1 number at a time, but don't …

Member Avatar for Nandomo
0
777
Member Avatar for glenc70

OK im not sure if this is a programming or pc problem but please read on ok i made a program to display playing cards in random locations using cards.dll just for a bit of fun but on my main PC which has 2.19 GHZ processor and 1 GB ram …

Member Avatar for glenc70
0
169
Member Avatar for steve_Student

Hi i am a total beginner and studying for a FD degree in C++. My assignment states Assignment Details a telephone company requires a program to calculate call charges for their customers. The regular charge rate for long distance phone calls is £1.50 for the first 3 minutes (or part …

Member Avatar for steve_Student
0
173
Member Avatar for lochnessmonster

Ok....so here is my problem. I want to release a library where with my dllInjection class, whenever the user instantiates an object, it will automatically perform the injection for the user. The only arguments they need to provide will be the processName, and dllName. Anyways my question is, i understand …

Member Avatar for mike_2000_17
0
244
Member Avatar for eagles39

I cant display a board for some reason I added a catch statemnt but there is something wrong with the if statment inside the for loop but i dont what is wrong thugh with the if else statement. [CODE]#include <iostream> #include <fstream> #include <string> using namespace std; const int size …

Member Avatar for eagles39
0
128
Member Avatar for aznlitomik3

[B]Problem:[/B] Write a program which reads a stream of integers from a file and stores them in an array. The array is then analyzed to compute the average of all the values in the array and all of the values that are above the average should be printed out to …

Member Avatar for aznlitomik3
0
285
Member Avatar for sahil1991

hi to al i was doin some programming till i encountered this problem in the followin code... i am nt able to find anythn wrong with the code bt it's nt showing the right result. #include<iostream> #include<conio.h> using namespace std; class person { char* name; public: void get() { cout<<"enter …

Member Avatar for fmadsen
0
109
Member Avatar for VasquezPL

I wrote small proggy..and I dunno why it doesnt work...can you help me? [CODE] #include <string.h> #include <stdlib.h> #include <iostream> #include <fstream> #include <iomanip> #include <string> #include <cstdlib> #include <sstream> #include <iostream> using namespace std; int main() { string option[] = {"option1.txt","option2.txt","option3.txt","option4.txt"}; string token; string filename_token; string line,filename,filename1,c0,c1,c2,c3,c4,c5,c6; int i=4; …

Member Avatar for VasquezPL
0
155
Member Avatar for kelechi96

I don't understand why my code crashes when the variable "dicerolls" exceeds 15 [CODE]#include <iostream> #include <fstream> #include <string> #include <stdlib.h> #include <iomanip> using namespace std; int main() { string a_or_b; string aorbreverse; unsigned short int dicerolls; string y_or_n; double ab = 0.5; double aa = 0.5; double ba = …

Member Avatar for kelechi96
0
131
Member Avatar for Mellopv13

Given positive intergers a and b, find their greatest common divisor, their least common multiple and intergers s and t such that sa + tb = gcd(a,b)[CODE][/CODE]

Member Avatar for mlesniak
0
86
Member Avatar for Emmitt310

Hello, my name is Jonathan and I am a beginner programmer in my first year of studies. I am using a Turbo C++ editor and I'm trying to set up graphics. The problem is I'm not sure how. Here's how i was taught to set up graphics: #include <graphics.h> int …

Member Avatar for musawir
0
892
Member Avatar for bigman91

I'm new to programming (only 4th week) and i am supposed to try and create a program that will... well ill just post what it wants as its alot. I'm just not sure how to get started on this as im drawing a blank on what to do. it is …

Member Avatar for Purrenhage
0
1K
Member Avatar for maverick405

Hi, I wounder if anyone can help me start a program which takes "USER INPUT" for any 10 numbers and then print them in reverse order using arrays what should I need to do to get started with this. Please help. Thanks, Maverick

Member Avatar for Rootz
0
142
Member Avatar for BimBam

Hi guys :) I'm stuck with same compiler messages since yesterday, and thought it might be helpful to aks for help :) The prog I'm developing is relatively big, so I'll post just snippets in order to describe what I'm doing. So, I have a class with a few subclasses. …

Member Avatar for alwaysLearning0
0
214
Member Avatar for SVSU_Student

I have read a file to an array successfully. However, when I attempt to pass the array to the function calcAvg(calculate average) and return the average, I get a zero. //Function prototype double calcAvg(double [], int); //Function call calcAvg(score,SIZE); I set a variable called score_length (in main) to get the …

Member Avatar for jonsca
0
221
Member Avatar for bookmark

For lines 23 and 22 it says "you cannot assign to a variable that is constant." anyone know how to fix this? thanks in advanced, bookmark. [CODE]#include <iostream> #include <string> #include <algorithm> using namespace std; void print (const string & s); string reverse(const string & s); int main(){ print("blah"); reverse("blah"); …

Member Avatar for alaa sam
0
148
Member Avatar for alaa sam

Hi I'm asked to write two functions to find the factorial one using recursion and the other using loops. the range of numbers which if have to output their factorials is 1 to 500(N) after some time the computer won't be able to find the factorial .I have to output …

Member Avatar for alaa sam
0
101
Member Avatar for yoyo59

Here's an assigment I was just emailed. After being ill for some time with mono I've been forced to teach myself the material. I have no idea what this assignment is asking for. "You are to write a program that reads in one integer first indicating the digits in length …

Member Avatar for WaltP
0
104
Member Avatar for Spiffy P Mcgee

I've gotten stuck on my assignment. The compiler says that the code is fine, but the program doesn't work properly. [CODE]#include <iostream> #include <iomanip> #include <fstream> using namespace std; void display_days (int []); void total_days (int []); void average_days (int []); void maximum_days (int []); void minimum_days (int []); int …

Member Avatar for jonsca
0
141
Member Avatar for slychronic

hie guys I am creaating a program employee data base its a simple c++ program tht should allow a user to input employee details view search edit and delete......now the prblem am having is i want to creat a function that will give an employee a num when entered i …

Member Avatar for slychronic
0
378
Member Avatar for lochnessmonster

im curious if there is any type of standard....or if anyone could help explain what all should be placed in .H files? (prototypes/etc) -thx

Member Avatar for mike_2000_17
0
266
Member Avatar for Rootz

This is my first post and I am just starting with arrays, but I am still stuck on how this function is suppose to work. I had to make two void functions and two-value returning functions. Main should call the getTestScores and get three test scores, then it should call …

Member Avatar for MasterGberry
0
133
Member Avatar for syok

i need answer for my asingment,please.....please using two dimentional arrays, write a function which multiplies an mxn matrix of integers by an nxr matrix of integers. Use global constant declarations before the main program to give test values for m,n and r, example input/output mingh be INPUT FIRST (2x2) MATRIX: …

Member Avatar for Ancient Dragon
0
82
Member Avatar for babaidebnath

Hi, I compiled the sample provided by Microsoft which created 3 files. Those are instlsp.exe, nonifslsp.dll, ifslsp.dll. So I installed it with instlsp.exe -i -o 1002 -o 1003 -o 1004 -n "Foobar" -d nonifslsp.dll Well its installed perfectly. But when now I tried open any web page, not opening. 1) …

0
50
Member Avatar for jae5086

This program is to calculate the average, high and low score of a series of use inputs. The output I am getting is high, low, average, high, low. I have no idea why or how this can happen. Side note, I am aware the coding isn't very good but the …

Member Avatar for jae5086
0
96
Member Avatar for iCode@Night

Hi all. I am trying to create a function to check if a string is a pangram or not. I think I have good start on it, but I can't figure out how to check if the characters in the string are unique. I have to do this recursively with …

Member Avatar for iCode@Night
0
688
Member Avatar for amishosh

Hi all! I would like to get more hands on programming for the languages I currently know: C Java C++ (studying now) The best way I figured is to join open source project and try to contribute. One place I found is SourceForge but I was wondering if any one …

Member Avatar for daviddoria
0
105
Member Avatar for Krysis

Hey all. Working on a Binary Tree of "N-order". For some reason I'm getting a fatal error while trying to compile my code. Let me know if you have any idea of what could be wrong, thanks. I'm actually trying to model this off an implementation written in Java: [url]http://koders.com/java/fidAB3BF22D2F6F383D797E598C79B9DE16C02ECF9A.aspx?s=tree#L1[/url] …

Member Avatar for daviddoria
0
258
Member Avatar for format_c

Hi.. i am totally lost with this random 20x70 maze generator i have to create. can some one give me some insight on how im supposed to start this? i know i use 2 for loops but my question is.. how do i create the actual blank space maze pattern.

Member Avatar for format_c
0
110

The End.