Search:

Type: Posts; User: Zeus_

Page 1 of 10 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    3
    Views
    142

    It's a very good read. Thanks for linking it here.

    It's a very good read. Thanks for linking it here.
  2. You might wanna look at a few resources to learn...

    You might wanna look at a few resources to learn more about warnings.

    Here are a few good ones:
    Why Bother with Compiler Warnings? - Cprogramming.com
    0.11 — Configuring your compiler: Warning...
  3. Replies
    60
    Views
    1,306

    Oh yes, my bad. Sorry about that. I subtracted 84...

    Oh yes, my bad. Sorry about that. I subtracted 84 instead of 86 which led me to think that the equation was wrong. Well done :)
  4. Replies
    60
    Views
    1,306

    That would work only for a specific test case,...

    That would work only for a specific test case, not all possible cases. If this formula was meant for the original test sample, your equation is wrong. Test it out yourself :)

    What was the sample...
  5. Replies
    60
    Views
    1,306

    Yep, I linked the book from the Amazon website in...

    Yep, I linked the book from the Amazon website in my post which says the latest delivery is by Tuesday but I didn't order it from Amazon lol :) Found another website that was delivering within 24...
  6. Replies
    60
    Views
    1,306

    Cool, thanks, just placed the order. Will arrive...

    Cool, thanks, just placed the order. Will arrive by tomorrow.
  7. Thread: C++ Challenge

    by Zeus_
    Replies
    4
    Views
    242

    I know that Floyd's algorithm is an O(N) solution...

    I know that Floyd's algorithm is an O(N) solution to finding a loop in a linked list. You might wanna read about it on Wiki or something. I learnt a version of it recently while solving an ICPC...
  8. Replies
    60
    Views
    1,306

    @Hodor, I'll be ordering the book you mentioned...

    @Hodor, I'll be ordering the book you mentioned above in post #39. Is it this Buy Godel, Escher, Bach: An Eternal Golden Braid Book Online at Low Prices in India | Godel, Escher, Bach: An Eternal...
  9. Replies
    40
    Views
    1,062

    Wow, just wow.... how many years have you been...

    Wow, just wow.... how many years have you been programming in C++? That's an insane amount of new knowledge that I came across when reading the last few posts on this thread.
  10. Replies
    60
    Views
    1,306

    Thanks for the reference! I'll look it up at the...

    Thanks for the reference! I'll look it up at the school library tomorrow (I doubt that I will find it). Yes, I'm interested in algos and math (math is my favourite subject i.e. people who have no...
  11. Replies
    60
    Views
    1,306

    It takes about 3 seconds on my laptop. Nah, it...

    It takes about 3 seconds on my laptop.
    Nah, it doesn't work on all kinds of inputs.

    CodeWars - Sample Problems
    HP CodeWars 2020
  12. Replies
    60
    Views
    1,306

    I think the Python solution was from one of the...

    I think the Python solution was from one of the student teams that submitted the solution. Yes, it doesn't work as you mention. I tried doing different things too, and matched with my brute force...
  13. Replies
    60
    Views
    1,306

    I found a solution to the problem in Python,...

    I found a solution to the problem in Python, although I don't understand the language much and find it weird. I feel that my choice of C/C++ at school was a good decision.
    This works, but I don't...
  14. Replies
    1
    Views
    138

    User-defined types to built in types

    Hey!

    Is it possible to have an user-defined type behave exactly like another type, the other type being a built-in type? Every reference to the user-defined type in code is to be treated as a...
  15. Replies
    3
    Views
    174

    Where's your attempt at converting this C++ code...

    Where's your attempt at converting this C++ code to C? That code is almost C...

    A vector is like an array. Make an array of size 62 and convert push_back accordingly
    cout to printf
    etc...
  16. Replies
    21
    Views
    941

    Hey, found some time and implemented a few more...

    Hey, found some time and implemented a few more things today. Okay, so I know that @laserlight mentioned that my code will have undefined behaviour i.e. behaviour that's not been accounted by the...
  17. Replies
    3
    Views
    173

    Your code tries to create an array of your...

    Your code tries to create an array of your structure where each structure object holds an an array. What you're intending to do is creating one structure object and accessing its elements (in this...
  18. Replies
    4
    Views
    160

    Remember to do what rstanley said next time...

    Remember to do what rstanley said next time onwards.

    Your minid function looks wrong. You must loop through your entire list to find the minimum which in your code just returns the first...
  19. Replies
    60
    Views
    1,306

    Really, graphing gave a solution? That's probably...

    Really, graphing gave a solution? That's probably the last thing I would have thought about if I were you lol. Thanks for the idea. I'll do the same and see what I can arrive at. I think it makes...
  20. Replies
    60
    Views
    1,306

    This is what I've got for john's test case. It's...

    This is what I've got for john's test case. It's interesting to see definitely. I was doing many simple test cases to come up with a binary math equation to predict the value at any time given the...
  21. Replies
    60
    Views
    1,306

    Hey, no problem at all. Feel free to get back to...

    Hey, no problem at all. Feel free to get back to it whenever you can, there's no hurry. I think we've all got brute force algos working but the key here would be finding the pattern of repetition and...
  22. Have a temporary variable that stores the value...

    Have a temporary variable that stores the value of what the user enters in the previous iteration, add a check that if new input == value held by temporary variable then "Error"
  23. Replies
    60
    Views
    1,306

    Your PMs still seem to be turned off.... Would...

    Your PMs still seem to be turned off....
    Would you mind sharing your brute force method so I can compare with my brute force method and find what I'm doing wrong that you are not? Thanks!

    Also,...
  24. Where's your indentation at? Does your main...

    Where's your indentation at? Does your main function take command line arguments? I don't think you ever use int argc or char **argv so why do you think it's important to have them there?
  25. Replies
    6
    Views
    255

    Where's your main function? int...

    Where's your main function?



    int first_team_score()
    {
    int score;
    printf("Enter the result of the 1st team(0-15):\n");
    scanf("%d", &score);
    if (score < 0 || score>15)
Results 1 to 25 of 234
Page 1 of 10 1 2 3 4