Basic programming course: Lesson #3 Operations [ESP-ENG]

in devwithseven •  3 months ago  (edited)
Hi, Greetings to All Steemians
White Simple Programming Course Video_20240927_181946_0000.png

It's really informative article and I am honored to be part of this challenge. Because through this contest, I have recalled my college days where I have learned a minor subject of programing in my Bachelor's degree program. Hopefully my educational experience will meet the requirements to winning contest. Let's move on to answer the flowing questions.


Give a brief summary of what arithmetic, comparison and logical operations are for

Basic mathematical functions are arithmetic operations. They are used to manipulate numerical values .The key arithmetic Operations comprise these:

¹Addition (+): It unites two numbers. They form a sum.

²Subtraction (-): It identifies the disparity between two numbers.

³Multiplication (): It increases two numbers combined.

Division (/): It sections one number by another.

Modulus (%): It offers the leftover from a division of one number by another.

These operations are fundamental in math and computer programming.

Comparison operations are Used to compare Two values The result of comparison operation is a boolean value It can be either true or false There are several operators for comparison operations .Common comparison operators are:

¹ equality to (==)

² inequality to (!=)

³ greater than (>)

⁴ less than (<)

⁵ greater than or equal to (>=)

⁶ less than or equal to (<=)

For example, if you are comparing the values x to y ,the output can only be true or false It will be True if x is equal to y It will be false if X is not equal to y

Logical operations are a group of operations that Involve values based on boolean algebra. They are used in computer programs to control the flow of the code .Logical operations include NOT, AND, OR.

NotANDOR
The NOT operation negates a given boolean value. . If the boolean value Is true ,NOT Operation will make it false.. If the boolean value is false NOT makes it true.AND operation Outputs true only if both input Values are true .If either or both of the input values Are false , the output will be false.The OR operation outputs true if any of The two input values are true .If both input values are false the output becomes false.

These logical operations help in making decisions in computer programs .They allow To control the flow of the code ,based on different conditions.


Make a program that asks the user for 2 numbers and evaluates if both numbers are the same

The top choice for crafting simple input-output operations can vary .This depends On the Environment You are working in.

It's easy to learn Python .Not only that ,Python is also one of the most widely used. It is used in technology.

You can't go wrong with Python .It is a great choice when you're starting out.

The following Is an example Python program. The program will request two numbers .It will then verify they are the same.

#  Asking for two numbers from the user
¹ = float(input("Enter the first number: "))
² = float(input("Enter the second number: "))

# Considering if the two numbers are same
if No¹== No²:
    print("The numbers are same.")
Else:
    print("The numbers are not 
same.")

Yes!!!! This program is not complex. .It is simple and easy to understand.. Python is often considered an ideal language for beginners.. This is due to its simple nature.

Python is ideal For simple programs like this .Python syntax is straightforward. The language has readable code.

Screenshot_20240927-233339.jpg

I used Online Python Editor App

In conclusion Python is one of the best Options for beginners .Its Simple syntax is especially beneficial. Without complicating the process the code can be read. Understanding is more accessible this way. The code is not As intimidating As other languages.


Transform the following mathematical expressions into arithmetic expressions on your computer

I have no much in deep experience of that coding operations . If you wish I can illustrate the Code in action. I'll give an example Using specific numbers .It Will demonstrate how the code behaves.

# Example inputs
num1 = 5.0
num2 = 5.0

# Checking if the two numbers are the same
if num1 == num2:
    print("The numbers are the same.")
else:
    print("The numbers are not the same.")

The following would be the output if both inputs were 5.0:

They are the same numbers

The result would be as follows if you entered various values, such as 5.0 and 3.0:

The numbers are not the same.

Well, Concluded, Understanding arithmetic comparison and logical operations is crucial for problem-solving in programming and mathematics. Arithmetic operations, such as addition, subtraction, multiplication, and division, are essential for manipulating numerical data.

These operations enable computers to perform tasks, decision-making, and systematic problem-solving, making their application and usage essential for any programmer or mathematician.


I would like to invite my Steemit fellows @drhira @abdullahw2, @ruthjoe and @eliany for your valuable feedback and participation. Thank you


Kind Regards 💐

@uzma4882

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:  

!upvote 50

  • Task 1: Excellent (3 pts)

Me alegra que te haya gustado el artículo y que hayas recordado buenos momentos de tus estudios con este curso, un placer que hayas participado y que hayas dejado tu comprensión sobre el tema de forma clara, felicidades

  • Task 2: Good (2 pts)

Desarrollaste el ejercicio de forma correcta, sin embargo para este ejercicio no debía utilizar condicionales ya que queríamos el valor de la operación lógica tenías que guardarlo en una variable y mostrarlo en Pantalla

  • Task 3: Incorrect (0 pts)

No desarrollaste el ejercicio tres, debías transformar las operaciones matemáticas planteadas A operaciones que se pudiesen desarrollar automáticamente por el código, después comparar los tres resultados y ver si ellos eran mayores que cero

DescriptionInformation
Grade5/10
Plagiarism Free
#steemexclusive
IA Free

Untitled design.png

You don't have enough bandwith.

Upvoted! Thank you for supporting witness @jswit.

Upvoted. Thank You for sending some of your rewards to @null. It will make Steem stronger.

TEAM 4

Congratulations! Your post has been upvoted through steemcurator06. Good post here should be..


post1.png

Curated by : @jyoti-thelight