CT26991

Opal's Polished Ledger

EasyL3 · Syntax SurferAcceptance: 0.0%XP: 20

The registry keeper Opal has been asked to secure the caravan contract. On the desk lies a long table of coins readings. 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 <= 243; -1000000 <= a[i],t <= 10.

Example 1:

Input: 234 -438566 -934833 -114713 -130491 -903060 -828276 -472527 -17432 -492308 -266245 -638557 -328130 -285597 -630795 -112375 -654839 -403347 -56312 -462133 -118379 -171630 -339770 -224333 -850850 -982197 -813847 -707972 -702109 -797990 -269884 -178144 -955223 -143561 -495733 -400012 -111897 -375632 -806847 -291278 -364600 -222535 -989405 -485897 -270908 -302617 -377525 -377746 -110047 -710500 -601510 -977973 -325465 -352851 -853271 -947588 -670506 -813881 -280804 -426604 -816764 -511158 -428508 -65889 -426184 -670839 -820054 -878698 -465419 -759526 -359671 -865980 -991071 -772859 -928097 -38537 -997491 -519056 -227250 -272182 -527713 -523565 -963609 -435949 -184558 -846671 -277416 -15914 -870900 -171434 -609843 -489133 -919571 -23610 -738144 -571980 -269791 -441295 -83310 -937855 -983876 -33…
Output: 93

Example 2:

Input: 71 -602774 -360586 -68728 -807221 -75030 -794145 -112889 -511747 -113253 -543601 -331226 -676245 -328444 -338801 -407770 -379705 -60589 -431253 -198049 -794795 -168607 -857702 -105916 -759228 -294297 -118779 -652983 -805151 -393015 -814581 -313024 -844204 -640275 -884331 -358944 -311887 -376903 -905135 -440998 -732459 -109589 -611134 -530114 -916193 -369709 -77101 -474652 -983666 -437434 -334794 -78285 -478843 -382655 -175019 -859515 -407927 -356598 -255653 -901776 -175986 -583932 -574006 -124643 -601747 -418038 -33605 -343251 -916434 -719935 -217442 -820127 -117429
Output: 49

Example 3:

Input: 17 -493704 -656649 -981318 -137902 -211027 -545634 -474649 -359428 -696818 -755606 -289188 -891573 -919846 -891062 -234956 -998285 -160100 -682672
Output: 7

Constraints:

1 <= n <= 243; -1000000 <= a[i],t <= 10.

Loading...
Test Cases:No test cases
No test cases available.
Opal's Polished Ledger - EASY Coding Problem | CodeTikki