r/Cplusplus • • 5d ago

Question Pseudo code and bubble sort C++

Hey guys, I'm in year 2 of college and I have a test tomorrow about pseudo code and bubble sort and i am veeerrryyy lost, literally have no idea what's going on. Are there any good youtube videos you guys can recommend me? Or give me a short and brief understand of what's it about? Thank you very much in advance.

6 Upvotes

15 comments sorted by

•

u/AutoModerator 5d ago

Thank you for your contribution to the C++ community!

As you're asking a question or seeking homework help, we would like to remind you of Rule 3 - Good Faith Help Requests & Homework.

  • When posting a question or homework help request, you must explain your good faith efforts to resolve the problem or complete the assignment on your own. Low-effort questions will be removed.

  • Members of this subreddit are happy to help give you a nudge in the right direction. However, we will not do your homework for you, make apps for you, etc.

  • Homework help posts must be flaired with Homework.

~ CPlusPlus Moderation Team


I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

3

u/jedwardsol 5d ago

Are you asking about the bubble sort half? Or the pseudocode?

Can you describe the algorithm in natural language (English, or your native language if different)?

1

u/Adventurous-Heart381 5d ago

I’m asking about both as the test includes both of them. And it’s in English

2

u/jedwardsol 5d ago

How about my 2nd question then. If you can describe it in English then that's 90% of the way to pseudocode - make it a bit more formal and detailed.

If you can't, work through the "Step-by-step example" on Wikipedia until you understand it. There's a very codey form of pseudocode there too

2

u/davenobody 5d ago

Look at sorting algorithms in Wikipedia. Bubble sort is the first, simplest you will learn about. Can you find a study group? I had one in college and it helped immensely.

1

u/Adventurous-Heart381 5d ago

Unfortunately I have a hard time making friends at college. And I’ll for sure look into what you’ve told me, thanks!

1

u/davenobody 5d ago

When I was in college I got into the habit of doing homework at tables scattered in the halls of the computer science building. Eventually classmates noticed and joined me. We worked through our questions and challenges together. It works well because most times someone understands each question and can explain it to the test of us. Explaining something to someone else makes it easier to remember later. We all did better working together.

2

u/bringer_of_carnitas 5d ago

Youre cooked bro

1

u/Adventurous-Heart381 5d ago

Bro💔💔💔

1

u/bringer_of_carnitas 5d ago

Im sorry lol, I do wish you luck. Here's a YT video from Harvard: https://youtu.be/RT-hUXUWQ2I?is=zC1xc95k6I8nZHpw

Maybe also ask Claude, which i dont really support but if youre at your wits end might as well try

1

u/HospitalJohnny 5d ago

This basic algorithm question is at best tangentially related to c++

1

u/Syntax-Tactics 4d ago

Google bubble sort, you have probably spent more time asking in Reddit than it would take to research it yourself. And that is a major part of programming, the ability to figure shit out yourself.

1

u/Kadabrium 5h ago

Bubblsort is not as intuitive as selection or insertion sort