PHƯỚC HƯNG OJ · THỬ THÁCH THUẬT TOÁN

#PCBSAU0000023. Chia pizza (Pizza Sharing)

HỌC THEO LỘ TRÌNH

Bài tập thuộc lộ trình

2 lộ trình

Chia pizza (Pizza Sharing)

Pizza Sharing

Source: Phước Hưng OJ

Version: Phuoc Hung OJ Extended

Problem Statement

There are nn people, pp pizzas, and ss slices per pizza. Distribute whole slices equally, without further cutting. Find slices per person and leftovers.

Input

One line with n,p,sn,p,s: people, pizzas, slices per pizza.

Output

Print slices per person and leftover slices on one line.

Subtask

  • Subtask 1 — 100 points: 1≤n≤1061\le n\le10^6; 0≤p≤1060\le p\le10^6; 1≤s≤241\le s\le24.

Example

Input

5 2 8

Output

3 1

Explanation

There are 1616 slices; 16//5=316//5=3 slices per person, with 16%5=116\%5=1 leftover.