CT22760

Zane's vials Reckoning

EasyL3 · Syntax SurferAcceptance: 0.0%XP: 20

Before the gates of the opal reefs of Shimmerdeep close for winter, Zane must finish the vials ledger - one figure at a time. Task: Print the minimum absolute difference between any two array elements. Input format: First line: n (>=2). Second line: n integers. Output format: Print the minimum pairwise absolute difference. Constraints: 2 <= n <= 459; 0 <= a[i] <= 1000.

Example 1:

Input: 180 764 282 176 947 126 138 136 105 278 81 753 209 1 118 668 845 970 767 42 727 166 394 682 837 158 124 990 222 522 482 141 750 824 429 956 711 50 952 193 338 722 987 569 32 998 313 708 259 531 743 599 61 269 814 915 400 285 942 19 725 683 640 448 906 696 538 191 721 907 210 597 777 158 217 614 21 652 203 322 597 947 531 299 791 530 50 834 237 311 813 923 364 757 878 829 635 311 272 993 871 122 964 305 216 669 177 56 186 670 419 272 23 269 23 998 430 735 909 652 323 263 111 895 237 356 942 400 830 816 217 947 28 994 35 421 669 39 256 123 726 288 322 760 884 750 247 721 532 830 834 608 222 815 622 443 65 830 344 985 883 608 80 189 395 443 850 800 659 51 102 529 391 642 737 37 541 673 85 820 947
Output: 0

Example 2:

Input: 273 734 348 764 534 146 432 834 219 957 471 64 951 449 2 640 804 367 709 214 436 446 463 94 459 840 383 876 340 501 769 536 741 193 534 568 566 762 718 193 121 111 56 326 809 272 567 213 353 41 702 586 576 263 578 693 782 337 858 650 388 421 502 765 129 632 31 220 71 397 683 604 255 480 387 66 873 685 988 194 471 209 264 111 250 353 368 574 581 15 934 552 800 69 150 703 338 241 540 519 93 645 458 72 455 489 954 513 856 633 35 969 336 940 537 23 52 400 598 679 940 739 586 11 830 906 297 395 897 263 328 869 992 317 887 380 196 297 505 955 679 799 629 22 745 936 635 208 187 516 430 768 457 60 902 853 781 14 340 315 948 787 171 734 935 312 315 308 392 701 553 781 823 882 785 849 454 275 113 456 858 958 238 188 569 370 389 200 367 398 898 964 341 475 48 542 764 579 890 755 610 14 943 359 421 19…
Output: 0

Example 3:

Input: 424 945 485 26 516 804 333 967 425 573 676 365 90 419 692 102 703 452 418 621 8 945 166 801 457 263 416 874 647 413 335 59 70 635 395 517 648 838 830 357 954 228 789 983 503 281 341 308 390 15 915 667 747 606 952 361 964 152 624 36 337 907 923 754 424 71 301 554 919 572 373 830 552 629 407 510 239 646 418 330 188 677 427 818 368 197 155 893 546 539 805 377 937 939 188 11 900 466 597 699 353 194 824 101 808 817 94 767 338 123 674 365 405 991 669 348 895 487 159 991 879 25 404 56 221 260 670 835 613 988 261 256 466 961 995 479 765 130 133 462 369 702 843 692 276 647 922 979 787 86 411 525 202 795 233 457 569 544 200 442 91 865 775 609 19 261 187 946 121 57 686 117 720 389 386 432 917 62 985 325 978 320 20 596 273 151 494 754 658 525 930 953 68 442 56 540 834 812 42 465 70 178 921 188 853 578…
Output: 0

Constraints:

2 <= n <= 459; 0 <= a[i] <= 1000.

Loading...
Test Cases:No test cases
No test cases available.
Zane's vials Reckoning - EASY Coding Problem | CodeTikki