Basic programming course: Lesson #6 Functions

in devjr-s20w6 •  last month 

Assalam-o-Alaikum!!!

Greetings to my all STEEMIT members. hopefully you all are fine and enjoying your best life on STEEMIt. I am also fine ALHAMDULLAH. And today iw ill share my Engagment contest task with all of you guys. I hope you will like and appreciate it more and more

image.png
Made in poster my wall

Tell us about your experience with programming, was it your first time? Did you find it complicated? What was your favorite part of the course? (2 points)

Programming for me can be both Especially when it first happened not often I found it difficult to learn logic and problem solving skills which can be tricky at first but rewarding once understood Mistakes Learning to overcome is an important part of learning. If we find and correct mistakes, our experience is better.

For many people, a programming course is designed by seeing a project work, be it a simple app or a game or solving a complex problem we have to debug and run successfully. This sense of achievement is often a characteristic of the character, just like for me it is also a source of happiness. It happens that when someone makes a mistake and my output is not coming out right, when I spend a lot of time finding such a mistake, I later realize that it was a very difficult mistake that I made. If I find and do it right, if I manage to solve a difficult task with hard work, then this is my favorite part

And the course that we started in these six hands, and after that, I think the best thing I've done is that there are a lot of programming programs that I left behind at work when I was studying. And I didn't do it again but I got to participate in this task so I felt very good that I learned a lot because of STEEMIT

Add the functions to multiply and divide to the course calculator. Explain how you did it. (3 points)
image.pngimage.png

So the out put of Multiplication function:

image.png

Output of division Function:

image.png

  • Explain how you did it

First of I want to tell you that I will perform two function. And here is the explainiatoin

  • Multiply Function:

This function just multiplies two numbers and it returns the result x and y for example if the value of x is 4 and the value of y is 5 then the result will be 20 x and y are used to multiply When User choose option 3

  • Division Function:
    This function divides x by y but there is an additional check to ensure that the divisor is not simply divided by zero. If the divisor is zero, the function returns an error message instead of performing the division.
  • Main Calculator Menu:

The user is presented with five options: addition, subtraction, multiplication, division, then exit. Displays option five to allow the user to exit the program

FINAL PROJECT: Create an ATM simulator. It must initially request an access pin to the user, this pin is 12345678. Once the pin is successfully validated, it must show a menu that allows: 1. view balance, 2. deposit money, 3. withdraw money, 4. exit. The cashier should not allow more balance to be withdrawn than is possessed. Use all the structures you learned, and functions. (5 points)

image.png


image.png


image.png


image.png

And the out put is:

image.png

image.png

Explain how it works:

The way it works is that the user will be asked to enter a Pin in and if it matches the pin they can move on and they have three tries and one thing when the pin Once verified, everyone will be presented with a menu where they can view their balance, make deposits and withdrawals, and up to their balance and exit the program. It is said that each option will be implemented as a function which makes it easier to manage the code modular

Special thanks to : @alejos7ven

Invite friends: @ruthjoe , @sehar78 , @josepha

Regards: @arinaz08

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  
Loading...

GIF_20240928_152908_070.gif