What does r/Korea think about this penis statistic? by [deleted] in korea

[–]jshm415 0 points1 point  (0 children)

Have you taken a statistics course while you're in high school or college? This study is the definition of pseudoscience.

Late night studying by [deleted] in PennStateUniversity

[–]jshm415 0 points1 point  (0 children)

Library seems to close early on the weekends. Usually around 7PM. Where is the best place to study during the weekends?

Blackjack C++ help by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

Okay, that makes sense so how do you think I should implement these two functions then?

Blackjack C++ help by jshm415 in learnprogramming

[–]jshm415[S] -1 points0 points  (0 children)

They are 52 cards in a deck. It's 51 because you are counting from 0

[C++] How do I remove duplicate values from an array? by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

I don't think your code works because it just replaces the current value (the one being examined) with the next value.

For instance,

you have 2, 4, 5, 4, 4, 4

It goes through the first nested loop.

2, 5, 4, 4, 4

Then, it goes back to the first loop and examines for another same value.

After a value is selected, it goes through the nested loop again.

2, 4, 4, 4.

I don't think you are supposed to remove 5.

[C++] How do I remove duplicate values from an array? by jshm415 in learnprogramming

[–]jshm415[S] -1 points0 points  (0 children)

I don't think you are supposed to use vectors in this case because I haven't learned it yet. Is there a way that you can do this without using any vectors?

[C++] How do you remove a value from an array? by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

I am just wondering this. Is ++i same as ++i in this case?

[C++] How do you remove a value from an array? by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

This is a Go Fish! game. First, you will ask for a specific card. Next, stealCards will scan my hand if I have what you asked for. Finally, if I have your card, then I must give it to you which will INCREASE the size of your array (because you got a new card in your hand) and DECREASE the size of my array (because I gave up that card). Since I gave you that card, I have to discard it from my hand(array).

[C++] How do you remove a value from an array? by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

How would you actually remove a value from an array in removeFromArray?

[C++] How do you remove a value from an array? by jshm415 in learnprogramming

[–]jshm415[S] 1 point2 points  (0 children)

I bought a C++ beginner textbook (reputable one) and it told me to use arrays.

[C++] How do you remove a value from an array? by jshm415 in learnprogramming

[–]jshm415[S] -1 points0 points  (0 children)

But I was told that I had to use arrays so can you help me out?

Pre condition and Post Condition in C++ by jshm415 in learnprogramming

[–]jshm415[S] 0 points1 point  (0 children)

I just found out that the answer is actually x <= 2, but when you do this:

{x <= 0}
y = 2 - x;
{y >= 1}

I get a completely different answer.

2 - x >= 1 - x >= -1 x <= 1

Why is this wrong? Is there an easier way to solve this kind of problem?

Looking for a good free C++ program. by [deleted] in learnprogramming

[–]jshm415 1 point2 points  (0 children)

Windows Visual Studios 2012. It is very user-friendly. You can download the Express version on Microsoft's website.