Beginners - November 2019 (Page 8)

Need quick help!
 
I'm new here, so I don't know how this works. I need help this quick assignment that I'm having trouble with. I don't have time to put in full effort with the e...
[2 replies] Last: Hello FutureCS, When you look at the instructions like this you see s... (by Handy Andy)
Help with grade calculator using arrays
 
I am writing a program that is supposed to (set a max possible points and find the number that refers to A, B, C D, F) compare an entered grade to a number that...
[6 replies] Last: Wow, I really appreciate the details that everyone has provided to me ... (by brownt898)
Delete last element of dynamic array
 
Can I delete the last element of dynamic array using delete operator ? example: int main(){ int n; cin >> n; int *arr = new int ; for(int i = 0; i < n...
[12 replies] Last: So is it correct ? No. #1 Deallocate everything that you have alloc... (by keskiverto)
Heap Corruption error in C++
 
Hello, In destructor when I w ant delete array I have heap corruption error. If I add array = NULL; before delete array, this problem has been solved. could yo...
[8 replies] Last: In other languages like C# and Java, we have Garbage Collector. In C a... (by Shervan360)
File Handling - Binary Problems
 
HELLO ,I AM NEW HERE!! I MADE A PROGRAM FOR MY SCHOOL PROJECT , BUT I AM FACING A PROBLEM(MORE LIKE A DOUBT) I USED FSTREAM.H(Turbo C++) AND OPENED A FILE IN...
[6 replies] Last: Easy on the caps-lock key tiger. http://www.catb.org/~esr/faqs/smart-q... (by salem c)
Help with reused equations
 
So I'm making a program where I use sorts. In my output I'm trying to print the time it took and the relative # of copies and compares. I'm doing a switch in my...
[9 replies] Last: I think you want something more like this: for (int i = 0; i < 5; i++... (by dhayden)
Organize terms (1,2)
 
I need to organize 5 million terms within a txt by the number of occurrences. What software can I use or how to do it in c ++?
[21 replies] Last: The key to this problem is recognizing that while you're counting item... (by dhayden)
how to have full words instead of initials as the input in this code
 
The following is the "rock, paper, scissors" game. The user has to enter initials (r, p, s) instead of the full words to play the game. Can anyone change the co...
[2 replies] Last: why in the heck would a user want to type all those letters to play? ... (by jonnin)
by Bopaki
error: expected primary-expression before '[' token
 
I am not sure what is it that they want me to type there before '[' I get this error message: C:\Dev-Cpp\Chapter2\listType.cpp: In member function `void li...
[6 replies] Last: The problem was in my insert function. Its all sorted out now. here is... (by Bopaki)
four sorts problem
 
so i'm suposed to write code for bubble sort, insert sort, quick sort, and selection sort, from pre-written algorithm pseudo code so they're not the normal sort...
[4 replies] Last: that just changed the problem, now i lost the first element and it pri... (by TheJast)
Having trouble with arrays.
 
Hey guys, I finished the first part of my assignment, but I'm stuck on this last part of it. I would very grateful for some help. Thanks in advance. P.S the pa...
[3 replies] Last: https://www.learncpp.com/ (by deleted account xyzzy)
Which operation has minimum time complexity!
 
Hye, everyone! Does anyone know which operation has minimum complexity and why? Chaining or Linear probing or Quadratic probing??
[7 replies] Last: Write a program to Find the Number in the HASH table with minimum com... (by dhayden)
find out if vector element exists
 
i am trying to use an element of a vector only if it exists (otherwise it will crash the program). i have found how to check the whole vector to see if any info...
[8 replies] Last: so i have to use the COORD values? there is no way to use the element ... (by tunplus)
Having trouble with while loop in main
 
I am trying to compute pi with a certain level of precision using the trapezoid method. However, I am encountering an error within my while loop, it is never e...
[2 replies] Last: Well, each of the while loops should do one numerical integration ... ... (by lastchance)
How can I improve this code?
 
Hello. Please consider the following code: #include <iostream> using namespace std; int main(int argc, char** argv) { enum object {rock, paper,...
[12 replies] Last: @keskiverto Thanks. I understand it now. (by jacks9807)
.cpp files and header files
 
hi i am new to C++ and i am still wrapping my head around the basics. i have learnt about headers and cpp files but im not sure about the proper use. am i ...
[12 replies] Last: thanks for the help guys! it seems i need to rethink how i am approach... (by tunplus)
Problem with MakeFile
 
Hi, I'm doing a project and I added some new classes. The problem is that now the MakeFile is getting some errors!!! :( g++ -g -Wall -c main.cpp g++ ...
[5 replies] Last: I changed it to private because it is based on a tutorial book, so in ... (by albertBcn92)
Char type is giving me headaches :(
 
I am trying to learn how to pass char, char*, char* into functions and such operations but.....I just don't understand! class Parent{ private: char...
[4 replies] Last: #include <iostream> #include <cstring> using namespace std; class Pa... (by lastchance)
Quicksort to sort integers
 
Is there something wrong in my quicksort code? void QuickSort(int A , int left, int right) { int j, k; if (left < right) { j = left; k =...
[2 replies] Last: So sorry about that. I'll know for next time. I also realized the mist... (by closed account jEb91hU5)
What can I do to improve this program?
 
I am having trouble with this question. I've only been coding for about 3 months so I'm very new at this. What I need help with is to make the program say "My j...
[5 replies] Last: and the original issue, even if you no longer want to do it this way: ... (by jonnin)
November 2019 Pages: 1... 678910... 17
  Archived months: [oct2019] [dec2019]

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