CT28895

Last crates of Kian

EasyL3 · Syntax SurferAcceptance: 0.0%XP: 20

Before the gates of the forest village of Briarthorn close for winter, Kian must finish the crates ledger - one figure at a time. Task: Read n integers and a threshold t; print how many exceed t. Input format: First line: n and t. Second line: n space-separated integers. Output format: Print the count of values strictly greater than t. Constraints: 1 <= n <= 242; 0 <= a[i],t <= 1000.

Example 1:

Input: 93 232 326 28 178 286 244 691 726 465 45 949 714 358 541 162 423 754 800 63 436 330 600 320 757 376 201 289 733 198 810 621 237 337 387 619 424 333 432 197 835 375 116 596 6 600 390 498 854 733 452 501 513 146 228 279 474 316 468 702 46 18 140 699 134 48 220 391 732 758 881 641 726 113 548 769 579 697 814 110 757 395 777 691 626 240 103 634 639 75 688 910 878 150 549
Output: 70

Example 2:

Input: 95 151 292 521 862 2 58 767 443 813 645 918 776 411 514 93 215 525 372 288 492 955 831 187 403 828 124 843 549 331 620 739 701 667 916 382 986 871 581 590 436 104 684 829 19 134 125 485 739 432 727 135 297 157 666 105 498 516 659 245 723 707 524 494 357 464 978 808 767 460 942 852 982 516 834 436 106 56 225 582 693 455 37 618 19 391 591 854 508 563 447 856 897 234 454 831 513
Output: 81

Example 3:

Input: 193 228 957 554 78 211 949 403 868 187 140 469 994 183 896 528 456 594 220 984 760 941 25 64 187 108 786 173 640 403 206 338 377 403 412 303 79 789 572 173 888 961 965 434 842 814 456 210 770 1 170 776 273 735 987 590 452 730 239 45 948 770 239 37 252 263 79 669 244 924 349 344 289 693 429 696 679 529 867 688 111 120 342 224 689 695 665 185 27 467 471 179 822 831 80 537 191 978 706 907 363 357 301 903 400 748 657 117 640 688 653 752 875 25 505 324 560 121 606 583 17 426 313 702 19 352 42 902 889 672 468 715 63 808 33 532 993 450 58 589 393 416 654 41 473 760 319 512 801 924 482 939 539 93 487 221 928 992 560 764 376 272 587 693 932 499 139 840 135 930 555 389 186 220 188 635 225 697 748 702 739 734 789 631 653 854 971 967 21 361 23 715 93 152 176
Output: 142

Constraints:

1 <= n <= 242; 0 <= a[i],t <= 1000.

Loading...
Test Cases:No test cases
No test cases available.
Last crates of Kian - EASY Coding Problem | CodeTikki