637 Topics

Member Avatar for
Member Avatar for amari ♥

hi guys! please help me understand anything about recursion and iteration ways of coding. :) (maybe some overview, details or something) thank u. we haven't had any further discussion about this. ;p but our teacher gave an exercise that goes like this: make a program that gets the summation of …

Member Avatar for saad749
0
224
Member Avatar for bkoper16

I need help with a program that is supposed to take data on football players from a txt file and place them in a binary search tree then use case statements to t osearch the tree inorder, preorder and postorder recursively here's what i got so far [CODE] /* Bradley …

Member Avatar for Narue
0
198
Member Avatar for lasl0w

Hey all, I'm implementing a hash table for a spell checker and need some assistance on vector const_iterator - at least I think that's where the problem lies. Can anyone assist in diagnosing how to fix these compiler errors? I initially got this error, which i think will come back …

Member Avatar for lasl0w
0
444
Member Avatar for bkoper16

I am doing a project where i have to insert a list of players and stats into a binary search tree Here is the project description For this final assignment, you will be creating a binary search tree. You will be able to utilize some of your previous assignment code, …

Member Avatar for bkoper16
0
878
Member Avatar for tdba.316

Hey :D this is my first post here^^, and it's a problem with an exercise from the book C++ Primer Plus, which I have been self-studying (I'm the beginner). The following code is how I did the exercise, which is in the header comment. It was built in VC++ 2010, …

Member Avatar for tdba.316
1
1K
Member Avatar for schoolboy2010

Hi, My program is supposed to implement a binary tree with an insert, remove, copy, pre-order, post-order and in-order functions. Problem is that my code compiles but doesn't work correctly. When I try to insert more than one node/child node the program crashes/freezes. Could someone help me out. Thanks. header …

0
197
Member Avatar for gpjacks

This is a program which declares two vectors of 6 elements each of type double. One vector is named weight and the other is named rate. The program uses a loop to prompt the user for a weight in ounces and a postage rate for that weight and then stores …

0
252
Member Avatar for erum

i have bit tricky kind or problem. i need to get values of each textbox in loop with different names,i have three row (name,telephone,email)and off course three textbox ,can any one help how to get in loop ,i need to insert them in database [CODE] Dim arr() As String Dim …

Member Avatar for shine_jose
0
208
Member Avatar for debbier

I need to iterate through an array, starting with the first element, in chunks of, say, 5, then break off and do something else with the array, then go back to where I left off. I'm confused about how the array counter, using next, or current etc. would work. How …

Member Avatar for debbier
0
163
Member Avatar for baldwindc

ifstream mystream(file_name); ofstream outputstream(filename, ios::out); do { mystream.getline(line, 100); mystream >> country_name >> happiness_value; total_happiness = total_happiness + happiness_value; count++; outputstream << country_name << " \t \t " << happiness_value << endl; } while (!mystream.eof()); the file ifstream is reading from is a .dat file, in this format: first 1 …

Member Avatar for baldwindc
0
1K
Member Avatar for theG-Scott

Thanks for taking the time to read this. Let me start by saying I'm a php newb so be gentle! I have a form that is used to insert data into my database to display info and images in a portfolio section on my site. In the form, the input …

Member Avatar for theG-Scott
0
278
Member Avatar for flyingcurry

The method below for bubble sort should work, it displays the unsorted array fine, but for the sorted array it only displays one of the numbers. It seems to have just skipped over the other elements in the array. Here is a sample output: [COLOR="Green"]How many random even integers would …

Member Avatar for apines
0
176
Member Avatar for MaryAnne19

Hi all! I have a program that runs as a large form (Form1) with smaller forms that open inside of it (PeopleBox). It's for friends/contacts - each person gets their own row in the database (PeopleDB). At runtime I'd like it to open a PeopleBox for each person already existing …

Member Avatar for N4JRY
0
244
Member Avatar for ohsevenfiveoh

hey guys,been browsing this site for a few weeks,but this is my first post. As you might guess by my problem I'm a C++ noob. I'm tryin to make a program in which the user inputs an array of double, I then use bubble sort to to get it into …

Member Avatar for Fbody
0
606
Member Avatar for Lance5057

Whenever I run this code the while(b<63) only seems to run once then does nothing. The (a<63) loop runs fine but doesn't go again because the first loop just stops. Any idea what's going on? [CODE]#include <iostream> #include <time.h> using namespace std; int main() { int a,b,c,sand; int land[64][64]; srand((unsigned)time(NULL)); …

Member Avatar for Lance5057
0
106
Member Avatar for mrar85

Hello, i'm a newbie with c++.. all help and explanation are welcome..my problem is, i try to make a factorial program in c++ . Here is my code: [CODE]#include <iostream> using namespace std; int main() { int a,b,fact=1; char key; do { cout<<"\nPlease enter a positive integer : "; cin>>b; …

Member Avatar for mrar85
0
2K
Member Avatar for sid78669

I recently had an assignment for an advanced coding class where I was to create a Binary tree from inorder and preorder traversals. I first started out by creating my ADT for binary trees and working with that to create a new tree. The way I worked it was that …

Member Avatar for arkoenig
0
154
Member Avatar for mike_2000_17

Hey y'all, I have been working on a tensor library (Nth-order multi-dimensional arrays) and I've been having trouble coming up with a good scheme for a multi-dimensional iterator template. Basically, I have a class template "tensor_container" which stores all the values of the N-order array (as a std::vector of one …

Member Avatar for mike_2000_17
0
248
Member Avatar for NH1

Here is my code first and then ill explain what im doing. [code=c] ds.Dispose(); ds = new DataSet(); db = new DBconnect(); Co = new Cards('S', Global.GlobalCompanyID).SetSql(); ds = db.GetDataSet(Co); dt = ds.Tables[0]; dr = dt.Rows[0]; Out = dr[1].ToString(); if (Out != "") { Time tm = new Time(""); // …

Member Avatar for Mitja Bonca
0
117
Member Avatar for cortez716

Okay here's what I'm trying to do use a for loop get 5 numbers from input ONE number at a time. Output the sum and average of the 5 numbers. I am only allowed to use a maximum of 2 variables to solve this problem. Heres my code so far, …

Member Avatar for WaltP
0
152
Member Avatar for neural_jam

What the title says. Basically, I have some code with 12 nested loops based on the code below, and may have to bump it up to 24. This works fine, but seems a little cumbersome, and can't help but think that there's a better way of doing it? All help …

Member Avatar for neural_jam
0
2K
Member Avatar for raheel_88

I'm having trouble with a for loop! I'm trying to solve a differential equation using Euler's method like so; [TEX]\displaystyle\frac{dy}{dx} = 7{y^2}cos(y^2)-3e^{xy}, \ \ \ 0 \leq x \leq 1 \ \ \ y(0) = 0[/TEX] This is solved using the algorithm [TEX]y_{n+1} = y_n + hf(x_n , y_n)[/TEX] Where …

Member Avatar for Unimportant
0
832
Member Avatar for peterman.k

I am going out of town and don't have access to my professor and / or tutors for the weekend, and we have an assignment involving a BST. I have done all of my insert, remove, and search functions, and went to the tutor about the remaining ones I have, …

Member Avatar for peterman.k
0
227
Member Avatar for nukabolhi

How can I get the values in Check box while loop in php. Pls give me some tips to get the values from the below php code. [CODE] $sql=mysql_query("select * from tree"); while ($result = mysql_fetch_array($sql)) { echo "<br>"; echo "<label> <input type=checkbox name=Test value=checkbox id=Test_0 > $result[fruit] | $$result[fruit_charges] …

Member Avatar for phpology
0
2K
Member Avatar for Coemgen3

Hi there, I have only just began the proccess of learning C# Programming (this week)returning to education as a mature student, one of the assessments I have been given is to find out how to, and then write a program using 'nested for loops' to display the 1,2,3 and 4 …

Member Avatar for kplcjl
-1
131
Member Avatar for MothershipQ

I have a 200 point program to write for school that says how much extra grain will be left in the silo and Tomorrow is the last day to turn it in. But something is wrong with my while loop. Could you help me out? Also, I'm writing this code …

Member Avatar for gerard4143
0
133
Member Avatar for kdott

hi all, i have a programming assignment where i read a text file through command line arguments. i then use that information to get a list of photos (just strings, not actual images) and a list of keywords that correspond to each of those photos. i am stuck on how …

Member Avatar for JamesCherrill
0
156
Member Avatar for philip.s

Hi guy's, I am missing something, what on earth is wrong with this script, I can not get it to insert all my values into a table. [CODE] $host="localhost"; // Host name $username="root"; // Mysql username $password="1234"; // Mysql password $db_name="database"; // Database name $tbl_name="input table"; // Table name $que …

Member Avatar for Caeon
0
81
Member Avatar for tonyfingures

Hey! guys, i need help figurering out how to make this program ran. Jack has decided his student organization is going to sell Oktoberfest shirts at Oktoberfest. In order to compete with other clubs, he wants to offer a 10% discount to anyone who buys 5 or more shirts. Also, …

Member Avatar for JamesCherrill
0
162
Member Avatar for midjam

Hi this is driving me a little crazy, have been looking everywhere for a solution for the last few days. I'm new to php and i'm trying to create a simple food shopping cart, i have a repeat region for food extras attached to the food item. [CODE=php]<table width="100%" border="0" …

Member Avatar for midjam
0
201

The End.