Beginners - February 2021 (Page 2)

by siid14
Functions place.
 
I wrote this code (below) following those guidelines: (1) write a function named “arrayToFile”. The function should accept 3 arguments: the name of a fi...
[5 replies] Last: To keskiverto and seeplus' point, what you're practicing is, actually,... (by Niccolo)
Two % for show % in C
 
Hello, For show % we need %% but for * we don't need ** I don't understand well. #include <stdio.h> int main() { const int value = 5; ...
[3 replies] Last: Because that's just the way it is. But the more proper reason is that... (by Ganado)
Assigning Variables to each Vector Value
 
Is it possible to assign different variables to each vector value ? I have this function here. I don't have much code written out yet I am just building it out...
[5 replies] Last: void Pill::definePills(int p) { vector<int> pillDef(p); for (int p... (by keskiverto)
by icezy
C++
 
I am to revise the program and correct the errors of the program and make varaibles a and b not accessible by ".". so that the output is: Here are a and b: 0 1...
[8 replies] Last: Thanks seeplus Can I chat you up privately? No. I'll only provide... (by seeplus)
Linked list copying via recursion
 
Hello, So I am trying to implement a recursive method to copy a linked list. I have the general idea down (or at least I think), but could definitely use som...
[2 replies] Last: this will work a lot better if your list had an insert function. eg ... (by jonnin)
Problem in making auto clicker
 
So the prob is that my auto clicker working out of the game but inside i can only write "2" not use the skill that set on the "2" key dis is the bugged part i g...
[4 replies] Last: the fixed source if anyone need #define WINVER 0x0500 #include <Wi... (by Darber2)
Logical problem
 
I'm to get an output of this: From: 10:20:30 After: 15:45:40 Now is: 2:6:10 but what am getting is no way close to it #include <iostream> us...
[6 replies] Last: I know but it's just for some personal purpose (by Learner1)
Problem With My OOP.
 
Hello! I am currently trying to make a pokemon game with OOP. When I try to run the program, over 100 errors pop up. I am using Visual Studio (Not that I think...
[5 replies] Last: Nvm, I fixed it. fyi: The error messages were (class @@ &&have been... (by HypeCoderPanda)
Why does it skip array index 0 ?
 
Write your question here. #include <iostream> using namespace std; int main(){ int arraySize; cout << "Enter the array size:"; cin >> arraySize; ...
[16 replies] Last: OK, thanks @ Furry Guy , I'll try that out! Edit: Well I'll be da... (by JRManx)
Does anyone know how to print this
 
This is the output: Target money: $20 Day 0 you save $0 so you have $0 Day 1 you save $1 so you have $1 Day 2 you save $2 so you have $3 Day 3 you save $3 so ...
[12 replies] Last: Without using the maths: #include <iostream> using namespace std; ... (by seeplus)
help with arrays
 
need help to do a program that asks for 6 sixs numbers and saves them in a vector then i need to do 3 subprograms 1 to calculate the biggest and the smalles...
[5 replies] Last: For a starter - for 1) and 2) consider (assuming that 2 means sum of t... (by seeplus)
Do While Loop Not Looping/Working
 
Hello. As you are probably aware, I am a student and this is for an assignment, but I am stuck. I have spent hours trying to change the code so that my program ...
[4 replies] Last: Hello mrsfizz9, As I managed to get the code to compile an run I disc... (by Handy Andy)
Fibonacci with dynamic programming not working!
 
Hi! I'm new to c++ and I'm trying to learn it by doing some recurison. However my fibonacci program (using dynamic programming) doesn't seem to work faster t...
[1 reply] : Pass your map by reference , not value. Otherwise it's a very expensi... (by lastchance)
questions about stl sort
 
After learning Sorting Algorithm,i have a thought on the criterion. criterion: if x=odd,y=even; x is large; else return x>y; so i write the code below. ...
[2 replies] Last: excellent explanation. get the point. thanks a lot. (by a7300235)
C++ approach to handling collections
 
Hi, Thanks for the help in advance. So as a learning project I'm building a customer information system but I'm coming at it in a way I was never allowed to c...
[8 replies] Last: Thank you Gentlemen all. JLBorges, you really made the point clearly ... (by TheManx)
Help! My calculator doesn’t work properly!
 
I keep getting “Invalidate operator. Try again”. What did I do wrong? #include <iostream> using namespace std; int main(){ char opr; ...
[2 replies] Last: I fixed it just now! Thank you so much! (by Minionmin)
String encoding coming from libcurl
 
Hello ! I'm struggling to reencode a string that is a HTML document. Everything works, except non standard characters (French characters but also some points !)...
[9 replies] Last: > On top of that I'm worried, I wanted my crawler to be really fast, (... (by salem c)
Logic error
 
Wondering why my math isn't coming out correctly? #include <iostream> #include <iomanip> using namespace std; double getStandard(double total); double getPre...
[2 replies] Last: Thank you. (by Awak3nDreams)
Having trouble with second method
 
Hello, My homework is asking me to make two methods with the first one being "enter one number and store the number in the respective global variable. Call ...
[2 replies] Last: Yeah I'm not a fan of using the global variables either but sadly I ha... (by av16352)
object division
 
As simple as it is seems confusing to me at the moment, How to divide 2 objects correctly. #include <iostream> #include <string> using namespace std; ...
[2 replies] Last: @coder777. thanks mate (by MaxGreen)
February 2021 Pages: 1234... 12
  Archived months: [jan2021] [mar2021]

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