1. Course
  2. Arithmetic
  3. Order of priority

Order of priority


Last updated: 8/22/2020 Difficulty: Easy

Create a C# program that requests an integer x from the user and print the result of the following operations:

  • -6 + x * 5
  • (13-2) * x
  • (x + -2) * (20 / 10)
  • (12 + x) / (5 - 4)

Input

  1. 2

Output

  1. 4
  2. 22
  3. 0
  4. 14

Solution

Arithmetic

5 / 8

Android App


Practice C# anywhere with the free app for Android devices.

Android App

Exercises C# by difficulty


Learn C# at your own pace, the exercises are ordered by difficulty.

Make a donation


Your donations support our work and contribute to the maintenance of the app.

Advertising


CookieOwn and third party cookies to improve our services. If you go on surfing, we will consider you accepting its use.