Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace p06.Bonus_Score
- {
- class Program
- {
- static void Main(string[] args)
- {
- int points = int.Parse(Console.ReadLine());
- double bonusPoints = 0;
- if (points <= 100)
- {
- bonusPoints = 5;
- }
- else if (points <= 1000)
- {
- bonusPoints = points * 0.2;
- }
- else
- {
- bonusPoints = points * 0.1;
- }
- if (points % 2 == 0)
- {
- bonusPoints += 1;
- }
- if (points % 10 == 5)
- {
- bonusPoints += 2;
- }
- Console.WriteLine(bonusPoints);
- Console.WriteLine(bonusPoints + points);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement