General C++ Programming - October 2014 (Page 5)

Closest Distance 2D Points
 
In the following code I don't understand why am I splitting the y left and y right. (closest distance between 2 points in 2D) Am I splitting the y left and ...
[4 replies] Last: I heard about this problem from coursera.org(Stanford algorithm lesson... (by oleg9419)
input using printf/scanf
 
I have a extreme hard problem on today's class. Please help! I am not quite sure how to store the value in this case.. The topic is called " limited summati...
[3 replies] Last: If you want to know how to use printf and scanf , follow these link... (by TwilightSpectre)
valgrind malloc error, pointer being freed was not allocated
 
==39800== Invalid free() / delete / delete / realloc() ==39800== at 0x4D9D: free (vg_replace_malloc.c:477) ==39800== by 0x10000C471: Tokenizer::~Tokeni...
[4 replies] Last: You don't have any member, token , that is assigned a value in the co... (by cire)
by Cyks
Setting a function to a variable?
 
I need to set a function to a variable of some kind. Then later in the program it needs to run the function that is set to the variable. The variable doesn't ne...
[2 replies] Last: I need to set a function to a variable of some kind. then So maybe ... (by soranz)
HELP!(LOOP AND FUNCTION)
 
a) Implement the function checkPrime(int n) that returns 1 if integer n is a prime number, and 0 otherwise b) Implement the function checkTwin(int n) that re...
[2 replies] Last: i figured it out thanks! (by cjchapa1)
Sorting names within a linked list
 
Hi I am at a lost of how to sort names in alphabetical order after having the user input them into a linked list. I manage to create a program that did have th...
[1 reply] : Bottom-up merge sort is a fast sorting algorithm that can be used to s... (by Smac89)
Runtime_error?
 
I'm trying to catch a runtime error. When I run my program under certain circumstances I get a box which tells me that there has been a 'Runtime error' though ...
[6 replies] Last: Thanks, I'm actually not good at error trapping at all. No Java backg... (by dominover)
Need HW help ASAP
 
Im very new to coding and I dont understand how to do this. can someone plz help? thanks 17. Write a complete program that will read your initials (first, mi...
[3 replies] Last: #include <iostream> #include <iomanip> using namespace std; int mai... (by speedypete)
Working with Enqueue/Dequeue
 
Hello guys, I am looking for some help and some reassurance if I am on the right track. I am most likely not, which is what I think. First thing I would like fo...
[4 replies] Last: Still in need of some help. I still can't find a solution to my Dequeu... (by Shuruki)
Can Someone Assist Me In Finding A website With C++ Solutions For Labs!?!?
 
Can someone help me find a website that provides the solutions for labs based on C++ chapters? Am currently doing a lab called Quartsal.cpp. Any assistance woul...
[3 replies] Last: No way. If you have no idea what you are doing and somebody else does ... (by keskiverto)
by SarK0Y
The techniques to guard buffers against overflow
 
Hi there, my Friends. :D here, i'd like to discuss the possible & the best techniques for subj. 1st & foremost, i would like to share my humble approach to...
[2 replies] Last: Yeah. actually, it's very idea to not multiply extraneous entities. Th... (by SarK0Y)
How to put an end of string mark at the end of each line in an array?
 
Basically I am writing a program that will ask the user to input some names and then I will sort the names. However, right now when I input the characters, it...
[1 reply] : Just cout << Names on line 25. EDIT: And erase line 24.... (by S G H)
May Someone Please Help Me Out With this Code? Thank You!
 
I made some changes to the code to see if it works, but it still is not working. So, can you post the correct coding for this program and provide an explanatio...
[1 reply] : Please use code tags. Edit your post, highlight the code that you pas... (by doug4)
Help with operator overloading
 
#include <iostream> using namespace std; int a (int num); int b (int num2); int a (int num) { num += 5; return num; } int b (int...
[2 replies] Last: Thanks for the reply, I'll check it out! (by Whooooo)
URGENT!!
 
If anyone would be willing to walk me through this I would greatly appreciate it. How would I change the private variables in the header files and the code in t...
[3 replies] Last: I tried to follow your directions is this right? #ifndef MY_PRIMARY_... (by bwilson1)
Big O Notation - HELP!
 
So im still learning programming and I have came across BIG O NOTATION. I don't really understand it after endless of tutorials and videos to help guide me thro...
[8 replies] Last: Big O is used to calculate algorithm cost. It calculates the cost base... (by JoshuaMostafa)
Hlep please
 
I'm supposed to be creating a program that is menu driven and uses several user-defined functions, orverloaded functions and references.. upon program execut...
[no replies]
Help me ! c++ partner
 
Hi everyone ! i have this problem but i can not solve it. write C++ for bubble sort. 1) ask user to enter 10 random numbers, generate array and sorted. 2) sele...
[no replies]
Array Help
 
Write a program to simulate a deck of 52 playing cards. Represent your deck as a 2D Array where the value in the cell is the position of the card in the dec...
[8 replies] Last: Maybe I did. My class is today so I will see what I'm doing wrong and ... (by MarkyMark)
whats wrong with my pgcd program ( pgcd meaning written under title
 
a pgcd ( plus grand commun diviseur ) is the biggest diviseur of 2 numbers ex: 15 can be divided by 1,3,5,15 30 can be divided by 1,2,3,5,10,15,30 15 i...
[1 reply] : A number between the max and the min will never be a divisor of the mi... (by doug4)
October 2014 Pages: 1... 34567... 38
  Archived months: [sep2014] [nov2014]

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