Beginners - March 2022 (Page 3)

by oddy
Why different posts have different amount of replies?
 
Some of posts easily earns tens of replies, but my posts often have only one or two replies. What is the reason of that?
[8 replies] Last: When I ask a question then I'm rather glad not to get many answers bec... (by coder777)
by Out2
Need some help write this for My class!
 
Write a program to calculate semester fees that must be paid by a student at a State university using the following values: Each semester unit ...
[8 replies] Last: Lines 26-29: If the number of units is out of range, you output a mes... (by AbstractionAnon)
Loop not stopping when it's suppose to
 
Hello. I'm trying to work on this code for a school project that calculates the earnings and streams of multiple songs. I can't get the loop to stop when it rea...
[8 replies] Last: As the original formatted: #include <iostream> #include <string> #i... (by seeplus)
program not compiling
 
hello i am working on this program for a class assignment, it does not compile I have been trying to figure it out. So far its like shooting in the dark. I am h...
[3 replies] Last: For readData(), you're not checking that the file has been opened OK. ... (by seeplus)
Help with arduino c++ code to count pulses
 
Hello, I'm requesting help to design and implement an Arduino C/C++ program to count each LOW to HIGH transition occurring in a train of pulses (generated by a ...
[1 reply] : Your code doesn't appear to have much to do with an Arduino or the tim... (by againtry)
arrays
 
Not sure where to go with this one, it has some description in the code. I have been trying to find the right info to complete the program. I am still working o...
[6 replies] Last: this is good. thanks for the help guys. (by HellocMonkey)
by bfears
imported txt file, display sorted ascending array.
 
I am importing a txt file with 100 random type double numbers. I need to take the numbers place them in an array and sort them in ascending order. Lastly I need...
[1 reply] : #include <iostream> #include <fstream> #include <vector> #include <al... (by lastchance)
Can you continue calculate on result?
 
Hi! I'm pretty new at all this coding and trying to figure things out. I got this homework to do a calculator, and I have. With some issues (like forever loo...
[5 replies] Last: Thanks guys! You are genius. I have been out for a couple of days with... (by Learningnotsowell)
Can't make getline work in C++ strings
 
I really don't know what happened but getline started to not working. Making it cin instead of getline works. #include <iostream> #include <string> ...
[6 replies] Last: Hey, thanks for your help. It's looking promising. But it looks more c... (by bydrachen)
Having (mulitple) issues with my code
 
Full disclosure: this is a homework project, so please do not give me complete answers on how to fix something, however please tell me whats wrong and hint at a...
[3 replies] Last: Furthermore, your code: double monthlyRate; // uninitialized variable... (by keskiverto)
Switch statement breaking code
 
have a dictionary program that loads a txt file into a vector then searches based on user input and returns the word, type and definition. The search doesn'...
[2 replies] Last: omg wow I had no idea.. thanks for that it works as intended. (by Aussiemang)
How to find all duplicate elements within a string vector, and output their indexes when found
 
I'm currently modifying an existing function that was originally built for searching elements for an int vector and I want to make it work for a string vector i...
[4 replies] Last: #include <iostream> #include <vector> #include <map> #include <string... (by lastchance)
How to find a common CHAR elements (case sensitive) between two vectors
 
As the title suggests, I'm looking for a way that would find any char elements that are common between two char vectors, in this instance, we have our input as...
[3 replies] Last: Thanks you 2 (by Tally123)
What is the maximum length of the string element in struct?
 
Hello, What is the maximum length of the name? #include <stdio.h> #include<stdlib.h> struct person { char *name; int age; }; typedef stru...
[5 replies] Last: https://www.guinnessworldrecords.com/world-records/67285-longest-perso... (by George P)
Won't calculate while in loop?
 
Been on this for hours. It wants to calculate the cost of prescriptions depending on the plan but for some reason, it will only do it after I put in a number ov...
[14 replies] Last: @OP Once you start introducing lots of repetitive code it is a good id... (by againtry)
I dont even know where to begin on these
 
(its an online teach yourself to code site) they do not give any examples or anything- they went straight from the basic concepts to this... Write a prog...
[3 replies] Last: build small and test often. take only the first one until it is done... (by jonnin)
convert double to hex and split that into 2 hex variables
 
Hey everyone, I'm new to c++ and I'm trying to convert a double to hex and split it. For example if the double is 1 it needs to be converted to hex and splitt...
[9 replies] Last: seeplus, indeed that was it, signed char is from -127 to to 127 and un... (by wimvandenborre)
my program is sending out a random number
 
The instructions are: Write a program that prompts the user for 2 numbers, finds the sum and finds the difference for those numbers and displays a descripti...
[6 replies] Last: thanks! the way you explained that was really helpfull! way better tha... (by BigNibs)
No constructor called?
 
When running this program line 55 in the code give these outputs in the terminal: Copy c Enough money ($150) for a goat! Raised:50 Lost:150 Copy c - is f...
[10 replies] Last: FWIW, using the following test code: class Test { public: Test(const... (by kigar64551)
Math challenge :) 120 to 255
 
Hey everyone, I'm programming a midi synth and need to convert notenumbers (0 to 127) to -128 to + 128 values for tuning a synth I totally have no idea o...
[18 replies] Last: [quote=lastchance]It's nearly 11 octaves! Would scare my cat at the to... (by George P)
March 2022 Pages: 12345... 7
  Archived months: [feb2022] [apr2022]

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