小玉的任务

班主任给小玉一个任务,到文具店里买尽量多的签字笔。已知一只签字笔的价格是1元9角,而班主任给小玉的钱是a元b角,小玉想知道,她最多能买多少只签字笔呢。

package 算法ti;

import java.util.Scanner;

 class P1421{
    public static void main(String []args){
        Scanner scanner= new Scanner(System.in);
        int a = scanner.nextInt();
        int b = scanner.nextInt();
        int c = 19;
        System.out.println(((a*10)+b)/c);
    }
}

猜你喜欢

转载自www.cnblogs.com/Otto-zha/p/11095655.html