洗衣服

来源:互联网 发布:qq飞车高压数据 编辑:程序博客网 时间:2024/05/01 23:09

洗衣服

Problem Description


X是一个勤劳的小孩,总是会帮助大人做家务。现在他想知道对于一根长为L的绳子能晾开多少件宽为W的衣服,显然这些衣服不能相互叠压。


Input
多组输入。
每组输入两个整数L,W。


Output
输出答案。
Example Input


10 510 4

Example Output


22

代码:

#include <stdio.h>#include <stdlib.h>int main(){    int n, L, W;    while(scanf("%d%d", &L, &W) != EOF)    {        n = L / W;        printf("%d\n", n);    }    return 0;}
原创粉丝点击