Under construction

Still being built. Things may change

Copyright

Interview

Time limit1sMemory limit128 MB

Summary
Given A songs and a rounded-up average I, find the smallest total copyrighted melodies consistent with ceil(total/A) = I.
Level

Easy2 of 10

Topics
Math, Implementation
Solved
No attempts yet

Problem

An album contains A songs. The album's copyright average is computed as

(the total number of copyrighted melodies included in the album) / (the number of songs in the album)

and then rounded up to an integer.

Given A and the rounded-up average I, determine the smallest possible total number of copyrighted melodies in the album.

Input

The first line contains two integers A and I.

1 <= A, I <= 100

Output

Print the smallest possible total number of copyrighted melodies.

Examples3

  1. Example 1

    Input
    38 24
    
    Expected output
    875
    
  2. Example 2

    Input
    1 100
    
    Expected output
    100
    
  3. Example 3

    Input
    10 10
    
    Expected output
    91