Beginners - December 2020 (Page 6)

Function
 
Hello guys.I'm new at c++ programming.I have a question for you.The question is : Add a new function that find how many students have avscores>5 and calculate t...
[1 reply] : Maybe something like: #include<iostream> #include<string> using nam... (by seeplus)
Running Program Again??
 
Hi everyone, I created the code below in response to an assignment I had, the code runs fine and its good to go as far as the assignment goes. However, I was ...
[3 replies] Last: Consider something like C++17: #include <iostream> #include <string... (by seeplus)
Decent GUI tutorial
 
Hello guys, I'm trying to magage my Engineer thesis and i am struggling with it. Like I'm trying to search how to use OpenDialogBox and everything is in C#, ...
[3 replies] Last: Actually the guy is using Stream^ mystream As a c++ beginner I am co... (by oggin)
swap words in a string/ simplify my code please
 
Q: in a given string, swap the second word with the one before the last. if there are less than 4 words then just delete the second one ex: "my name is laura fi...
[4 replies] Last: @oggin. n is defined but not initialised before it is used - hence cou... (by seeplus)
adding some features to my code.
 
I want to add features to my code that I don't know how to construct or logic it out. My desired output STRINGS Apple Grapes Lemon Mango Peach Enter value...
[16 replies] Last: Sorry, my computer needed some repair these past days. Thank you, @s... (by seghrein2300)
Passing function ptr to template function
 
template<typename T> void templateTest(T **&arr, int n, float (*key)(T)) { for(int i = 0; i < n; i++) { cout << key(arr ) << ", "; } cout ...
[1 reply] : Your ptr_example_key takes in an Example* (pointer-to-example), but yo... (by Ganado)
assignment help
 
have to do this assignment and my professor does not reply at the moment and my assignment is due to 15th of december. Really need help with this program since ...
[10 replies] Last: @jlb Thanks for the correction. (by MikeyBoy)
I want to call a function more than once, but it uses static variables.
 
I am trying to simplify some code for an embedded processor. Currently it has several similar low pass filter functions which need to remember the last returne...
[5 replies] Last: If I declare a variable in a function its lifetime ends with the func... (by MikeyBoy)
by me743
nested structs
 
int fn() {return 5;} struct outer { int (*FnPtrA)(); struct middle { struct inner { int (*FnPtrB)(); int ...
[4 replies] Last: Thank you. That was driving me nuts. Apparently I also need to do o... (by MikeyBoy)
help with assignment
 
i have no idea how do i even form this program let alone make it. My assignment entries will close in 3 hours and i need this finished asap. Hope i get help her...
[3 replies] Last: [See other post] (by seeplus)
Load multiple class objects from file OR save/load vector of class objects
 
Hi there Stuck again... I have a class for player characters and store all instance of this class in a vector. So far so good. Now I want to store all player...
[12 replies] Last: [quote=seeplus]char usually, but could be wchar_t or other types for u... (by Peter87)
Dynamic table (like a 2d array, but with vectors): How to increment size (like push_back)?
 
Time appropriate greetings! For something that I am working on I need a dynamic table of objects. (So like a 2D array, but with vectors) Because I don't kn...
[13 replies] Last: There are several different ways to iterate through a std::vector . T... (by George P)
set method c++
 
modify the set method so it can change the nbOfWagons and weightPerWagon public: FreightTrainRoute() : TrainRoute("", "", "Necunoscut") { nbOfW...
[4 replies] Last: Frankly, the implementation of FreightTrainRoute::FreightTrainRoute(s... (by keskiverto)
derivate classs in c++
 
modify the implicit constructor of freighttrainroute it will initialize the nbOgWagons with 0, the vector of weightperPerson with nullptr, destination and depa...
[3 replies] Last: Consider: #define _CRT_SECURE_NO_WARNINGS #include <string> #inclu... (by seeplus)
Fireworks in C++
 
SO I need to code silver swirling dragon fireworks in C++, how do I do it? what will I need?
[5 replies] Last: You can draw graphics using OpenGL. My example shows how to draw a rot... (by Observer)
Stuck with sorting struct array
 
Hi i'm new here and a total newbie to C++, i was tasked with creating a program that gives the user to view a list of TV series either by a) listing them all b)...
[7 replies] Last: <algorithm> sort has more capabilities than qsort. https://www.cpluspl... (by salem c)
Vector Not Found Error! (sorting txt files)
 
I've spent the last 12 hours writing a code that is supposed to take two text files, one containing names and the other numbers, and merge them into one text fi...
[6 replies] Last: I managed to get it going using you all as a reference. Thank you all ... (by Struglling84)
Populating matrix diagonally from cordinates
 
Hello, here is the example of inputs and outputs. input: 6 10 R .......... .......... .......... ..P....... .......... .......... where 6...
[6 replies] Last: Here's an idea that might help you to think about directions just bein... (by salem c)
error in vs 2019 ??
 
any idea how I can fix this error please ?? https://i.postimg.cc/TPBVRj6C/Untitled.png << System.Resources.MissingManifestResourceException: 'Could not...
[no replies]
Calculate the registration fee
 
Okay, so I'm trying to write a code that calculates the registration fee of different vehicles based on a given criteria. I'm supposed to write outside function...
[6 replies] Last: Hello kmcfall, Thank you for the input file. Very helpful. As mentio... (by Handy Andy)
December 2020 Pages: 1... 45678... 11
  Archived months: [nov2020] [jan2021]

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