Beginners - February 2020 (Page 9)

Need help with app
 
Hello, I need help to create a simple app where you need to insert the amount of players and their names. The players drops dice from 0 to 99 and the biggest...
[8 replies] Last: Ganado, Thank you so much. You are my savior! (by mario883)
Help with Test Cases
 
I'm doing a program that I need 3 test cases with. I know what I'm doing wrong, it expects only 3 parameters and I use more. Not sure how to fix it though. Thi...
[1 reply] : You have declared, but never defined, a function cases(). (by lastchance)
Vectors for College Class
 
**Hey, I am rusty on C++ and my college professor just dropped this question to us. He barley brushed on the topic and I have no idea how to do vectors. Can any...
[5 replies] Last: Thanks for the helps guys! (by MrIDKWHATIMDOING)
by joe809
Error With Swapping Two Words from a String (Reverse)
 
I'm trying to output the two words in a string in reverse order. For example, if the first word in the string is "Baseball" then the second word is "Basketbal...
[15 replies] Last: #include <iostream> #include <sstream> #include <string> using namesp... (by lastchance)
by bor90
problem with equasion
 
Hello, I've got problem with my code. The results of equasion are weird and the same for any value I tipe in edit. Please help. It's in c++ builder 6, and unfor...
[7 replies] Last: I've moved that logic as you said, but it still gives same results, n... (by dhayden)
Bool
 
Can someone help me fix this code #include <iostream> #include <string> using namespace std; int main(){ bool answer; cout << "Is Dutch...
[19 replies] Last: Hello cblack618, You are welcome. Sorry for the delay I lost track o... (by Handy Andy)
Accessing one element of array when Inputing
 
I am trying to access an element from an array I created in my code. I want the final output of my code to print the string of the Class the user types in. ...
[3 replies] Last: No, I mean this: for (int i = 0; i < (sizeof(Class) / sizeof(*Class));... (by coder777)
Recursion Palindrome (1,2)
 
I need help and don’t know what I’m doing MFor this assignment, you will create a program that tests a string to see if it is a palindrome. A palind...
[36 replies] Last: Infighting by the self-appointed giants starts and it's only day 2. (by againtry)
problems with asserts on kattis 'falling apart'
 
doing the kattis problem "fallingapart" for my cs3 class and solving the problem wasn't bad, but we're suposed to add asserts and i dont think i understand what...
[2 replies] Last: thank you, i think i understood what you were saying, i made some chan... (by TheJast)
Unable to run this program, please help
 
//Gina AdamsSpiller //CSCI 1010 //This program will caculate BMI #include<iostream> #include<string> using namespace std; int main() //Display message; ...
[2 replies] Last: Hello Gspiller81, The only things I can add to what Duthomhas has s... (by Handy Andy)
Longest period PRNG in <random>
 
uh. Yeah. What the title says. What prng in the <random> header has the longest period? I’m trying to make a super simple stream cipher, and I like being exce...
[13 replies] Last: Hm.. I’ll look into it... Just so you know guys my question was answ... (by highwayman)
by joe809
Reading Multiple Lines from String
 
I'm trying to read multiple lines from a string that the user inputs. For example, the user inputs two lines of strings. adnasndansdas asdnasndonasodn I'm...
[3 replies] Last: I got it working to return all lines. I placed the for loop inside of ... (by joe809)
Why this garbage character after cout?
 
Hello, I tried the below in two different compilers (Visual Studio and gdb online). Any idea why I am getting the garbage characters after printing "December 31...
[5 replies] Last: Very good. Thank you! (by mrpear2020)
How can I 'stringstream' char data type array?
 
Hello, I am trying to combine two array of data type "char" as demonstrated below. So it seems if I do 'std::stringstream << array_char , this is not accepted. ...
[3 replies] Last: Thank you, helios and all. #include <sstream> did it! (by mrpear2020)
number of months.
 
Write a program to find the number of months in the given interval where Sunday after the second Friday is also the second last (penultimate) Sunday of the mont...
[5 replies] Last: Latest 2nd Friday for any month: 14th. Earliest penultimate Sunday: 3... (by booradley60)
How to retrieve Last element from Linked List
 
Hi, I'm trying to implement some basic functions for a Singular Linked List. The one I'm currently working on at the moment is the Last function. The purpose of...
[17 replies] Last: Your new code for addFront and removeFront may work, but it's ineffici... (by dhayden)
virtual inheritance and sizes
 
I know why the size of Derived1 is 1 but why the size of Derived3 is 8 what does virtual keyword do in this place regardless of preventing double inheritance ? ...
[2 replies] Last: Thank you (by ahmad alghadban)
How to call access class private members with function
 
We learned about classes in my class and were told to basically convert a previous assignment so that it uses classes. I can't figure out how to use my function...
[3 replies] Last: Here are some indications of problems with loadsongs() : - parameter ... (by dhayden)
By reference or by value parameter?
 
Hi everybody, If I have a recursive function having a signature like this one below, I'm wondering if the recursive call will pass the entire vector or if it's...
[9 replies] Last: Passing the iterator isn't significantly less memory intensive than pa... (by againtry)
by Bopaki
I get this error when compiling
 
Use of unidentified identfier 'find_len' /* Summary: Linked list is an ordered set of data elements, each containing a link to its successor. This program ...
[5 replies] Last: Suddenly everything worked fine after I declared the prototype at the ... (by Bopaki)
February 2020 Pages: 1... 7891011... 13
  Archived months: [jan2020] [mar2020]

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