Cody

# Problem 44075. GJam 2017 Kickstart: Parentheses (Large)

Solution 1130050

Submitted on 25 Feb 2017 by Richard Zapor
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

### Test Suite

Test Status Code Input and Output
1   Pass
v=parenc(36499,40104); assert(~isempty(v)) assert(v==666106750)

2   Pass
v=parenc(75814,21934); assert(~isempty(v)) assert(v==240561145)

3   Pass
v=parenc(88684,2943); assert(~isempty(v)) assert(v==4332096)

4   Pass
v=parenc(63688,19182); assert(~isempty(v)) assert(v==183984153)

5   Pass
v=parenc(71034,19757); assert(~isempty(v)) assert(v==195179403)

6   Pass
v=parenc(95210,572); assert(~isempty(v)) assert(v==163878)

7   Pass
v=parenc(50000,50000); assert(~isempty(v)) assert(v==1250025000)

8   Pass
v=parenc(37583,54023); assert(~isempty(v)) assert(v==706259736)

9   Pass
v=parenc(13403,50583); assert(~isempty(v)) assert(v==89826906)

10   Pass
v=parenc(74324,16176); assert(~isempty(v)) assert(v==130839576)

11   Pass
v=parenc(95662,20); assert(~isempty(v)) assert(v==210)

12   Pass
v=parenc(84426,8859); assert(~isempty(v)) assert(v==39245370)

13   Pass
v=parenc(1764,75732); assert(~isempty(v)) assert(v==1556730)

14   Pass
v=parenc(75135,17355); assert(~isempty(v)) assert(v==150606690)

15   Pass
v=parenc(16014,48995); assert(~isempty(v)) assert(v==128232105)

16   Pass
v=parenc(100000,0); assert(~isempty(v)) assert(v==0)

17   Pass
v=parenc(90812,5679); assert(~isempty(v)) assert(v==16128360)

18   Pass
v=parenc(55860,34690); assert(~isempty(v)) assert(v==601715395)

19   Pass
v=parenc(82678,16936); assert(~isempty(v)) assert(v==143422516)

20   Pass
v=parenc(50696,22228); assert(~isempty(v)) assert(v==247053106)

21   Pass
v=parenc(60183,19425); assert(~isempty(v)) assert(v==188675025)

22   Pass
v=parenc(88288,3180); assert(~isempty(v)) assert(v==5057790)

23   Pass
v=parenc(18628,32214); assert(~isempty(v)) assert(v==173510506)

24   Pass
v=parenc(99681,195); assert(~isempty(v)) assert(v==19110)

25   Pass
v=parenc(7,13); assert(~isempty(v)) assert(v==28)

26   Pass
v=parenc(62367,35577); assert(~isempty(v)) assert(v==632879253)

27   Pass
v=parenc(54171,29950); assert(~isempty(v)) assert(v==448516225)

28   Pass
v=parenc(22417,8626); assert(~isempty(v)) assert(v==37208251)

29   Pass
v=parenc(37824,9490); assert(~isempty(v)) assert(v==45034795)

30   Pass
v=parenc(95981,624); assert(~isempty(v)) assert(v==195000)

31   Pass
v=parenc(57025,7699); assert(~isempty(v)) assert(v==29641150)

32   Pass
v=parenc(1,1); assert(~isempty(v)) assert(v==1)

33   Pass
v=parenc(16007,35971); assert(~isempty(v)) assert(v==128120028)

34   Pass
v=parenc(2306,52078); assert(~isempty(v)) assert(v==2659971)

35   Pass
v=parenc(70555,4927); assert(~isempty(v)) assert(v==12140128)

36   Pass
v=parenc(19454,63092); assert(~isempty(v)) assert(v==189238785)

37   Pass
v=parenc(73352,18081); assert(~isempty(v)) assert(v==163470321)

38   Pass
v=parenc(71344,18591); assert(~isempty(v)) assert(v==172821936)

39   Pass
v=parenc(76452,13351); assert(~isempty(v)) assert(v==89131276)

40   Pass
v=parenc(88885,3106); assert(~isempty(v)) assert(v==4825171)

41   Pass
v=parenc(53619,9977); assert(~isempty(v)) assert(v==49775253)

42   Pass
v=parenc(39466,15681); assert(~isempty(v)) assert(v==122954721)

43   Pass
v=parenc(33791,51813); assert(~isempty(v)) assert(v==570932736)

44   Pass
v=parenc(40408,42624); assert(~isempty(v)) assert(v==816423436)

45   Pass
v=parenc(998,12); assert(~isempty(v)) assert(v==78)

46   Pass
v=parenc(58818,23613); assert(~isempty(v)) assert(v==278798691)

47   Pass
v=parenc(82533,6389); assert(~isempty(v)) assert(v==20412855)

48   Pass
v=parenc(73823,18704); assert(~isempty(v)) assert(v==174929160)

49   Pass
v=parenc(24046,69819); assert(~isempty(v)) assert(v==289117081)

50   Pass
v=parenc(83603,2337); assert(~isempty(v)) assert(v==2731953)

51   Pass
v=parenc(95719,1658); assert(~isempty(v)) assert(v==1375311)

52   Pass
v=parenc(9,11); assert(~isempty(v)) assert(v==45)

53   Pass
v=parenc(29910,7601); assert(~isempty(v)) assert(v==28891401)

54   Pass
v=parenc(59540,36291); assert(~isempty(v)) assert(v==658536486)

55   Pass
v=parenc(45871,53970); assert(~isempty(v)) assert(v==1052097256)

56   Pass
v=parenc(92763,325); assert(~isempty(v)) assert(v==52975)

57   Pass
v=parenc(9038,44798); assert(~isempty(v)) assert(v==40847241)

58   Pass
v=parenc(1,0); assert(~isempty(v)) assert(v==0)

59   Pass
v=parenc(86549,6287); assert(~isempty(v)) assert(v==19766328)

60   Pass
v=parenc(14401,46864); assert(~isempty(v)) assert(v==103701601)

61   Pass
v=parenc(93424,6259); assert(~isempty(v)) assert(v==19590670)

62   Pass
v=parenc(52933,31692); assert(~isempty(v)) assert(v==502207278)

63   Pass
v=parenc(91388,2050); assert(~isempty(v)) assert(v==2102275)

64   Pass
v=parenc(83487,14454); assert(~isempty(v)) assert(v==104466285)

65   Pass
v=parenc(26996,20778); assert(~isempty(v)) assert(v==215873031)

66   Pass
v=parenc(88436,1856); assert(~isempty(v)) assert(v==1723296)

67   Pass
v=parenc(52967,22634); assert(~isempty(v)) assert(v==256160295)

68   Pass
v=parenc(24373,71635); assert(~isempty(v)) assert(v==297033751)

69   Pass
v=parenc(25964,41310); assert(~isempty(v)) assert(v==337077630)

70   Pass
v=parenc(89807,7750); assert(~isempty(v)) assert(v==30035125)

71   Pass
v=parenc(84029,12987); assert(~isempty(v)) assert(v==84337578)

72   Pass
v=parenc(23884,41559); assert(~isempty(v)) assert(v==285234670)

73   Pass
v=parenc(96652,1790); assert(~isempty(v)) assert(v==1602945)

74   Pass
v=parenc(72470,2981); assert(~isempty(v)) assert(v==4444671)

75   Pass
v=parenc(51157,44196); assert(~isempty(v)) assert(v==976665306)

76   Pass
v=parenc(5964,125); assert(~isempty(v)) assert(v==7875)

77   Pass
v=parenc(5011,79606); assert(~isempty(v)) assert(v==12557566)

78   Pass
v=parenc(54850,32315); assert(~isempty(v)) assert(v==522145770)

79   Pass
v=parenc(94427,666); assert(~isempty(v)) assert(v==222111)

80   Pass
v=parenc(61766,28774); assert(~isempty(v)) assert(v==413985925)

81   Pass
v=parenc(90805,8083); assert(~isempty(v)) assert(v==32671486)

82   Pass
v=parenc(50250,34260); assert(~isempty(v)) assert(v==586890930)

83   Pass
v=parenc(59514,16501); assert(~isempty(v)) assert(v==136149751)

84   Pass
v=parenc(21448,21340); assert(~isempty(v)) assert(v==227708470)

85   Pass
v=parenc(48294,20183); assert(~isempty(v)) assert(v==203686836)

86   Pass
v=parenc(0,100000); assert(~isempty(v)) assert(v==0)

87   Pass
v=parenc(0,1); assert(~isempty(v)) assert(v==0)

88   Pass
v=parenc(9321,9795); assert(~isempty(v)) assert(v==43445181)

89   Pass
v=parenc(33373,207); assert(~isempty(v)) assert(v==21528)

90   Pass
v=parenc(78080,18989); assert(~isempty(v)) assert(v==180300555)

91   Pass
v=parenc(89341,7009); assert(~isempty(v)) assert(v==24566545)

92   Pass
v=parenc(0,2); assert(~isempty(v)) assert(v==0)

93   Pass
v=parenc(2,0); assert(~isempty(v)) assert(v==0)

94   Pass
v=parenc(90124,7716); assert(~isempty(v)) assert(v==29772186)

95   Pass
v=parenc(36611,12311); assert(~isempty(v)) assert(v==75786516)

96   Pass
v=parenc(45498,3564); assert(~isempty(v)) assert(v==6352830)

97   Pass
v=parenc(28355,23958); assert(~isempty(v)) assert(v==287004861)

98   Pass
v=parenc(58516,24422); assert(~isempty(v)) assert(v==298229253)

99   Pass
v=parenc(42157,56858); assert(~isempty(v)) assert(v==888627403)

100   Pass
v=parenc(32854,55517); assert(~isempty(v)) assert(v==539709085)

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!