Jump to content

JonnyBoyThan

Member
  • Posts

    104
  • Joined

  • Last visited

Awards

This user doesn't have any awards

JonnyBoyThan's Achievements

  1. Oh okay. During the task explanation it explained to set initialAge to age so by impulse I just took it to mean what I coded. Thank you!
  2. I don't really understand this issue all too well. I'm just doing a problem on HackerRank that's part of the 30 days of programming challenge and I've got to the point where my code looks alright but it's still producing many errors. For instance, whenever I input a number it will simply output "You are young." two times for every number I input. Here is the code: // ConsoleApplication5.cpp : Defines the entry point for the console application. // #include "stdafx.h" #include <iostream> using namespace std; class Person { public: int age; Person(int initialAge); void amIOld(); void yearPasses(); }; Person::Person(int initialAge) { // Add some more code to run some checks on initialAge if (initialAge > 0) { initialAge = age; } else { age = 0; cout << "Age is not valid, setting age to 0." << endl; } } void Person::amIOld() { // Do some computations in here and print out the correct statement to the console if (age < 13) { cout << "You are young." << endl; } else if (age < 18 && age >= 13) { cout << "You are a teenager."; } else { cout << "You are old."; } } void Person::yearPasses() { // Increment the age of the person in here age += 1; } int main() { int t; int age; cin >> t; for (int i = 0; i < t; i++) { cin >> age; Person p(age); p.amIOld(); for (int j = 0; j < 3; j++) { p.yearPasses(); } p.amIOld(); cout << '\n'; } return 0; }
  3. Wow. Thank you. I never would've know that c in c time meant character time if you hadn't said anything.
  4. When I try to run this code I get the error: 'void srand(unsigned int)': cannot convert argument 1 from 'char *' to 'unsigned int' and under it argument of type "char *" is incompatible with parameter of type "unsigned int" The language I am coding in is C++. Here's a pastebin link to my code: http://pastebin.com/cMBQdDGp (Feel free to criticize as I'm new to coding and I want to learn how to code clean code :D)
  5. I just went to a nearby Barnes & Noble (Bookstore) and picked up a book about C++. Specifically, I picked up the book C++ without Fear Third Edition by Brian Overland. But there was a huge variety to choose from. My high school doesn't offer programming or computer science courses sadly.
  6. I'm 15 and I've been having a lot of fun learning about C++ but was wondering if there was any way I could make some side money through C++/any other languages I learn in the future. Specifically, is there any place I can go to find people who want to hire programmers for a side project of some sorts? Thanks! EDIT: This would obviously be in the future as I'm almost positive I haven't even scraped the surface of all that C++ has to offer.
  7. Yes, those workedbut new updates came, supported win10 etc etc so I wanted to download them.
  8. Long story short, I've had countless problems with MSI's killer ethernet and I don't want to screw up my internet conection this time. I still haven't redownlloaded the killer ethernet feature even after I got rid of it to solve the internet problems. Does anyone know if they updated the killer ethernet drivers to not let all hell loose when you download them? Thanks!
  9. Basically, no one can hear my microphone after I start cs go because the levels go from 100 to 60 and make it too quiet for anyone to hear. Any way to prevent the microphone levels from switching?
  10. that download uitility is the cause of the errors, or at least that's how they pop up. I did the scan you said to do and I'll type exactly what it said. "Windows Resource Protection found corrupt files and successfully repaired them. Details are included in the CBS.log windir\Logs\CBS\CBS.log. For example C:\windows\Logs\CBS\CBS.LOG. Note that logging is currently not available in offline servicing scenarios." What should I do now?
  11. Been getting these the same errors the past week. https://gyazo.com/27f5cee401c515f06817063ed5d54fbe https://gyazo.com/5e8500e3aa731010704e7e7714ed31b4 https://gyazo.com/c60c9240e91ab2d17ef7c43b18abc488 All I'm trying to do is update my intel i7 4790k chipset drivers on my msi gaming 5 mobo. It's so frustrating because my headset won't work without these drivers I'm pretty sure because the pc cannot recognize the usb. If anyone could help I'd be so thankful. MOBO MODEL: MS-7917
  12. I've used this. Says it doesn't detect any drivers for my product.
  13. No, I know I'm very close I just need to get past this one barrier of not having the SetupChipsetx64 file.
×