
please wait
Passing function pointers to a class without knowing the function signature |
Hi, I am relatively new to C++ and I am working on a personal project for practicing where I need to create a class that can take function pointers with differ... |
Nov 20, 2020 at 5:17pm
[9 replies] Last: a little over my head... haven't ever tried to do this, but .. you co... (by AbdelrahmanSaid)
|
by volodstaimi
help with this question
|
Write your question here. Question:You are given a grid as shown in the figure below. You can determine the color and number of each square from the grid. Write... |
Nov 20, 2020 at 4:59pm
[6 replies] Last: > Note: You cannot use arrays to store the matrix information. Instruc... (by salem c)
|
by cnplusplus
string.h - How can I delete a string?
|
Hi Team, I am a student. I need delete a string, this need work in Linux. We are using string.h but we do not have any coomand as "clear" or "erase", ... |
Nov 20, 2020 at 4:42pm
[5 replies] Last: the simplest way to delete a file is to borrow the operating system. ... (by jonnin)
|
by ga3199
making an arrow
|
Write your question here. I have been working on this all day and can not figure it out. I need to get the end of the arrow shaft to make a point and my arrowhe... |
Nov 20, 2020 at 1:57pm
[8 replies] Last: Reminds me of seeing this some time ago: https://www.youtube.com/watch... (by againtry)
|
by siabapet
How to Calculate Grams to Ounce and Pounds
|
Convert grams to ounces and pounds, if 1 ounce = 28,3495 gram and 1 Pound = 12 Ounce. If anyone ask why 1 pound = 12 ounce not 1 pound = 16 ounce, yes its wron... |
Nov 20, 2020 at 11:55am
[4 replies] Last: Hello siabapet, I would start with salem c's suggestion of working ... (by Handy Andy)
|
by liam401
Function display issues
|
Hello, I having some trouble with my countCharacters() function. when i run the program everything works as intended but when I run the function twice as seen b... |
Nov 20, 2020 at 9:48am
[5 replies] Last: it adds both functions together ch_cnt needs to be set to 0 at the... (by seeplus)
|
by MattlttaM
Program isn't infile-ing the my infile.
|
So, the problem I'm having is that my functions either aren't opening the file to drag out the numbers or just isn't pulling the numbers at all. I adjusted a sh... |
Nov 20, 2020 at 4:05am
[3 replies] Last: Don't worry, it's a mistake a lot of people make, especially when usin... (by Ganado)
|
is this bad practice? |
I am trying to implement sudoku rules in this code for a 2d array. The code works. Logic tells me i am doing a lot of things wrong, but i feel i am a genius. ... |
Nov 20, 2020 at 3:37am
[8 replies] Last: I am not sure what the point of summing a partially filled board is? Y... (by TheIdeasMan)
|
by marystew
Undefined reference error: id returned 1 exit status
|
When I try to compile my code by typing 'make' I get the error: Marathon.cc:(.text+0x3e1): undefined reference to `View::validPos(Position&)' Marathon.cc... |
Nov 19, 2020 at 11:42pm
[3 replies] Last: Oh, I get it now. You aren't putting ClassName:: before the member fu... (by Ganado)
|
by DonnaPin
returning vector indices
|
Hello, I am trying a leetcode problem basically for the first time (tried a few weeks ago and didnt know vectors so didnt get very far). I have just went over v... |
Nov 19, 2020 at 9:04pm
[12 replies] Last: Hi, thanks again for all the replies. Some of the stuff I have not cov... (by DonnaPin)
|
by noahk81
How to split a string into a pre determined amount of parts
|
I am making a function that has to split an inputted string into 3 parts. The string will be inputted in the following format, Book Title|Year Published|Author ... |
Nov 19, 2020 at 7:06pm
[1 reply] : If you are able to directly extract user input, you can simply use get... (by Ganado)
|
by seghrein2300
ctypea program (1,2,3)
|
I just wanted to ask what is used in this program? is it loop with an if/else? https://imgur.com/a/GuOM0Fd I tried doing it but every time I look down "- ... |
Nov 19, 2020 at 4:14pm
[56 replies] Last: Hey guys, I'm sorry I have not posted the clue here but it is said and... (by seghrein2300)
|
by rovert456
Help with understanding class
|
I thought I had figured out how to create classes, until I had to use numbers in them. The example I was given did not use them, and the problem for my assignme... |
Nov 19, 2020 at 3:40pm
[4 replies] Last: Thank you jonnin, I wasn't sure if that's what I was meant to to or no... (by rovert456)
|
by marystew
Initiating and printing dynamic 2D array of characters
|
I'm trying to iterate through a dynamically allocated 2d array of characters and initialize all of the spaces to a blank. When I attempt to do this in the const... |
Nov 19, 2020 at 2:56pm
[3 replies] Last: #include <iostream> #include <string> #include <vector> using namespa... (by lastchance)
|
by liam401
Opening a txt file within a function
|
Hello all, Im having some trouble figuring out how to correctly open a txt file within a function. I understand I need to use ifstream input.file(), but im ... |
Nov 19, 2020 at 12:35pm
[4 replies] Last: Without a function: #include <iostream> #include <fstream> #include... (by seeplus)
|
by allisonOs
C++ Reading Records from Disc File, Sorting, and Finding the Average
|
Hi everyone. I hope all is well. I am having trouble with my code below. For my C++ class, my professor has just uploaded an assignment that requires us to r... |
Nov 19, 2020 at 11:57am
[9 replies] Last: @allisonOs See my previous post! (by seeplus)
|
by Leonardo797
counting words
|
I have tried the code below #include <iostream> #include <string> using namespace std; // function prototype int countWords(char*); int countW... |
Nov 19, 2020 at 11:50am
[3 replies] Last: As the first post is C++, this can be easily done in C++. If you extra... (by seeplus)
|
by Leonardo797
storing data on a .dat file
|
solved it using below the code if someone needs help /* Corporate Sales Data Write a program that uses a structure named CorpData to store the following... |
Nov 19, 2020 at 11:19am
[5 replies] Last: Note changes to the function definitions: #include <iostream> #incl... (by seeplus)
|
by kidd2100
Trouble shooting Nested Loops and statements
|
Having trouble with Odd Portion of this code. I am over looking how I have written the code to have the desired effect which is listed below. Ive nailed the eve... |
Nov 19, 2020 at 11:19am
[7 replies] Last: Hello kidd2100, You are welcome. Glad it helped. Andy (by Handy Andy)
|
by howardcheng
array + struct: extra curly brackets required for initialization?
|
Are extra curly brackets really required when initialize structures comparing with primitive types? It's kind of inconsistent design, can someone help explain? ... |
Nov 19, 2020 at 10:09am
[11 replies] Last: Actually, my advice would be to use a vector - it's more flexible. (by lastchance)
|