Beginners - June 2019 (Page 10)

Number theory
 
How to divide an array of integers into two arrays having atleast one element each such that the GCD of array1 + GCD of array2 is maximum.
[8 replies] Last: The problem seems to be described much better in the other thread: htt... (by keskiverto)
Binary Tree constructor sometimes works, sometimes not
 
For a college workshop I had to implement a Set template class following a Binary Tree structure, and have it succesfully run a series of preset Tests; two of ...
[1 reply] : - indent your code properly (don't mix tabs and spaces) - don't abbrev... (by ne555)
SFML static linking error
 
I tried to make static linked bin. Here is code. #include <SFML/Window.hpp> int main() { sf::Window window(sf::VideoMode(800, 600), "SFML window"...
[8 replies] Last: acknowledged (by dutch)
Advice for my Perfect Card Shuffle Program
 
Hey guys, I have the "Create a deck of Cards, perform perfect shuffle, and return to original order" - hw assignment, and it all works great! The only thin...
[4 replies] Last: I would regard value for counting and sequence of significance during ... (by MikeStgt)
vending machine using strusctures
 
hello so my coding prompt is "Write a program that simulates a soft drink machine. The program should use a structure named Drink that contains the followi...
[16 replies] Last: Hello mercedx, Good job. Glad to hear it. Andy (by Handy Andy)
Please Help!!
 
Hey guys- I wrote this code and am completely lost :( I can not use any arrays or vectors. Any help is greatly appreciated!!! My code is below, I just can't s...
[10 replies] Last: Hello koaken, That is some improvement. At least it compiles with no ... (by Handy Andy)
Need advice/tutorials transitioning to modern OpenGL(3.3+), preferably SDL2-based.
 
I have been using SDL2 and started tinkering around with OpenGL tutorials on the web a while back. It has come to my attention that most of them are outdated, a...
[8 replies] Last: Thank you for taking so much time to explain all of these things to me... (by closed account Ezyq4iN6)
error::'item' does not name a type
 
i have this problem (error::'item' does not name a type) and i cant figure it out.If you can help me i would appriciate it.Thanks in advance. #ifndef HASHT...
[5 replies] Last: I can't say for sure, why not try it out and see what happens? Experim... (by Ganado)
Compiler error any feedback helps
 
New to C++ and i am having a little trouble with this problem I feel like i'm declaring the variables wrong but do not know what exactly. ANY FEEDBACK HELPS. ...
[4 replies] Last: thanks for the info guys really clarified everything and program runs.... (by starterpack6100)
C++ Tutorials
 
I am running Ubuntu MATE 19.04 and i like using the command line. I have been looking around for upto date C++ tutorials that i can use.
[2 replies] Last: this may help. a compile batch file for simple gettng started programs... (by jonnin)
Constructor Help
 
I need to add a constructor to this code, but I don't know how, even after looking it up. The code does everything it should, but apparently, it needs a constru...
[3 replies] Last: srry ive been in other classes. Thats a great idea, repeater, I meant ... (by Eristato)
Can you bring law and order to this piece of code?
 
- case credit, debit - } - enum Card: String { - var description: String { - return self.rawValue - } - var C = Card.credit - print(c.description)
[2 replies] Last: It's Swift. (by Ganado)
please help with this code
 
#include <iostream> using namespace std; int main() { int test = 0; cout << "First character " << '1' << endl; cout << "Second charact...
[3 replies] Last: Really, you ought to just avoid using different types that might have ... (by Ganado)
Need assistance regarding accessing the private function
 
Hi, I need to ask about accessing the private function, which I am unable to do after multiple attempts. I am new to C++ programming. Your assistance would b...
[9 replies] Last: @lastchance, Thanks so much dear... :) Your solution clarified my con... (by zarrar12)
by GonlyG
Can't read in multiple lines
 
I'm trying to read in a number which is how many lines of input I have (each line is three strings), but when I press enter to input the second line (for exampl...
[4 replies] Last: Hello GonlyG, Here is the answer to your problem _ ... (by Handy Andy)
Help with Programming (1,2)
 
Write your question here. Brand new programmer in a class and could use all the help I can get. Working on an assignment of a program outputting a grad...
[21 replies] Last: What exactly does the text file you are trying to read contain? 88, 90... (by Manga)
How to instantiate an object in a try block, but keep it in scope? (1,2)
 
What I have is a class with some various if statements in the constructor that test conditions and throw exceptions if they are not met. In my main the object i...
[22 replies] Last: No apology needed. I think it is interesting to read all of the commen... (by closed account Ezyq4iN6)
how to display photo
 
i want to show a photo in my graphical interface, while the program is still , but the photo is not displayed. (i use windows.h library). please tell me how to ...
[3 replies] Last: i want to show a photo In case it is for nothing else but to dispaly... (by MikeStgt)
question about reinterpret_cast
 
Hi everyone, in this piece of code, ch is a pointer that points to a character. I understand that *ch is A, but why ch the pointer itself is also A? Shouldn't i...
[2 replies] Last: but why ch the pointer itself is also A? Shouldn't it be the memory a... (by Ganado)
Need advice
 
Hye everyone! So I have covered Structures, object oriented programing etc in the second semester. Now the next subject is data structures. So should I just foc...
[3 replies] Last: Thanks! (by lost110)
June 2019 Pages: 1... 8910111213
  Archived months: [may2019] [jul2019]

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