CT23849

Lila's Sum Ledger

EasyL3 · Syntax SurferAcceptance: 0.0%XP: 20

In the orchid house of Bloomglass, Lila the auditor keeps careful count of the readings. Schedule the next expedition, every figure matters. Task: Read n integers and print their total sum. Input format: First line: n. Second line: n space-separated integers. Output format: Print the sum of all n values. Constraints: 1 <= n <= 644; -1000000 <= a[i] <= 1000000000; answers fit a signed 64-bit integer.

Example 1:

Input: 601 802221749 717411255 192701305 452919380 946429791 488561025 643246360 425989986 987442221 471040960 366527789 160129082 547020898 438620330 89749812 939543235 403881501 243622664 985042690 78169858 701722474 13586696 836099866 35889819 495135892 223875262 546813143 77993576 303628796 156015632 248137848 314846750 476254674 771477229 913586405 550562130 82037635 775773413 321681143 323257360 591472228 448685603 835769965 669999597 167484707 551437083 983255854 161147463 978135343 35195530 731913377 473190915 146876009 343644459 902885858 780443698 491390627 829063796 750052001 356102889 30253247 988156435 914174618 583470208 501820774 583864902 247487935 467903579 673597897 983937439 336744856 777978036 957467786 142188804 980443715 719212426 544929902 766039861 592757024 71844546 87564…
Output: 311921593548

Example 2:

Input: 26 868249920 144936299 479033000 950854931 402764288 870953184 788826738 34027338 953377694 676573910 988059838 657208531 903603031 135812917 982827464 207548291 391122027 406447604 233717571 151638841 170920141 842557764 54240425 826316216 890325910 217396033
Output: 14229339906

Example 3:

Input: 508 892360471 526325866 204141962 681745153 458081861 504861803 630602513 166558647 398803103 428604797 766939090 37536353 662452819 217826346 567975503 395319033 88608188 241497743 583101555 93271597 337600685 474345378 121677102 686053426 918137246 581204565 670029052 1354080 646512133 791342068 926100480 906879360 200343114 923511397 642849738 539036296 531010033 213220506 464634535 558274163 635334834 192538857 92051345 945578207 544106679 948638371 965669907 721569937 385398375 491466631 217621774 603149556 353605122 160394019 638044150 986897247 596177228 80957006 665689325 107576099 996869950 723698459 641576818 979613254 428043318 964548257 493716317 139132064 870652803 832778120 682515489 394905753 366256039 354997146 522948666 816390146 805439288 630133066 570053081 983398254 141…
Output: 246683091099

Constraints:

1 <= n <= 644; -1000000 <= a[i] <= 1000000000; answers fit a signed 64-bit integer.

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