Learn C# (C sharp) in FREE step-by-step lessons.
Unit I: Introduction

Learn all about performing arithmmetic operations in C#
In this lesson, you will learn how to use arithmetic operators to perform simple math problems.
Objectives:
- Identify and tell the purpose of each arithmetic operator;
- Know the order of operations and role of parenthesis;
- Evaluate an arithmetic expression;
- Apply operators to solve problems;
- Write a function;
- Convert an algebraic expression to C# code;
- Use a scroll bar to select decimal values.
Please study the material at each of the links below.
Arithmetic Operators in C#: C# Operators
Microsoft Reference: C# Operators: C# Operators
Drill: Operators: Do this drill to make sure you understand
Centering a control on the form: The control is centered when the form is resized
Drill: The % operator: Drill on the % operator: remainder- Finding Dozens: A program to select quantity on scroll bar and display dozens: quantity%12
Finding Feet and Inches: A scroll bar selects inches, feet and inches is displayed- Order of operations: The Order of operations for arithmetic operations is to do parenthesis () then *, / %, then + and - working from left to right.
Drill: Order of operations: Test how well you can solve these problems- Calculate Grade: Scroll bars select midterm and final exam, average is calculated
- Write a function: Write a function to avoid the same code in two places
- Algebra to code: Convert algebraic expressions to programming statements
- Decimal values on scroll bars: Value on scroll bar is integer, how to select a decimal value
A function to display values on the scroll event and also form load: Calculate tip, avoid misinformation at form load- Real world math: A few real world problems you can solve in C#
Glossary for Arithmetic Operations
Full Glossary