Advertisement
Graf_Rav

Untitled

Sep 23rd, 2018
258
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.75 KB | None | 0 0
  1. /*
  2.  * Решается задача:
  3.  * Cond7 https://ulearn.me/Course/BasicProgramming/Zadachi_na_seminar_609e4aa9-0d76-4e33-90a8-b3340b266391
  4.  * Автор решения: Шарафеев Равиль, 11-808
  5.  */
  6.  
  7. using System;
  8. using System.Collections.Generic;
  9. using System.Linq;
  10. using System.Text;
  11. using System.Threading.Tasks;
  12.  
  13. namespace ConsoleApp3 {
  14.     class Program {
  15.         const double Eps = double.Epsilon;
  16.  
  17.         static void Main(string[] args) {
  18.             string[] input = Console.ReadLine().Split();
  19.             double x = double.Parse(input[0]);
  20.             double y = double.Parse(input[1]);
  21.             double n = double.Parse(input[2]);
  22.  
  23.             Console.WriteLine(Math.Ceiling(n * ((x + 0.05 - Eps) - (y + 0.05 - Eps)) / (y + 0.05 - Eps - 1)));
  24.             Console.ReadKey();
  25.         }
  26.     }
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement