Cody

Problem 44074. GJam 2017 Kickstart: Parentheses (Small)

Solution 2286292

Submitted on 16 May 2020
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   Fail
v=parenc(19,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test1 (line 1) v=parenc(19,1);

2   Fail
v=parenc(14,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test2 (line 1) v=parenc(14,4);

3   Fail
v=parenc(4,15); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test3 (line 1) v=parenc(4,15);

4   Fail
v=parenc(8,6); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test4 (line 1) v=parenc(8,6);

5   Fail
v=parenc(14,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test5 (line 1) v=parenc(14,1);

6   Fail
v=parenc(10,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test6 (line 1) v=parenc(10,2);

7   Fail
v=parenc(10,10); assert(~isempty(v)) assert(v==55)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test7 (line 1) v=parenc(10,10);

8   Fail
v=parenc(3,7); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test8 (line 1) v=parenc(3,7);

9   Fail
v=parenc(3,13); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test9 (line 1) v=parenc(3,13);

10   Fail
v=parenc(4,12); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test10 (line 1) v=parenc(4,12);

11   Fail
v=parenc(2,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test11 (line 1) v=parenc(2,2);

12   Fail
v=parenc(6,11); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test12 (line 1) v=parenc(6,11);

13   Fail
v=parenc(4,12); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test13 (line 1) v=parenc(4,12);

14   Fail
v=parenc(15,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test14 (line 1) v=parenc(15,5);

15   Fail
v=parenc(14,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test15 (line 1) v=parenc(14,3);

16   Fail
v=parenc(20,0); assert(~isempty(v)) assert(v==0)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test16 (line 1) v=parenc(20,0);

17   Fail
v=parenc(12,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test17 (line 1) v=parenc(12,3);

18   Fail
v=parenc(0,10); assert(~isempty(v)) assert(v==0)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test18 (line 1) v=parenc(0,10);

19   Fail
v=parenc(18,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test19 (line 1) v=parenc(18,2);

20   Fail
v=parenc(16,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test20 (line 1) v=parenc(16,4);

21   Fail
v=parenc(3,12); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test21 (line 1) v=parenc(3,12);

22   Fail
v=parenc(8,12); assert(~isempty(v)) assert(v==36)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test22 (line 1) v=parenc(8,12);

23   Fail
v=parenc(8,6); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test23 (line 1) v=parenc(8,6);

24   Fail
v=parenc(1,8); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test24 (line 1) v=parenc(1,8);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test25 (line 1) v=parenc(7,13);

26   Fail
v=parenc(7,6); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test26 (line 1) v=parenc(7,6);

27   Fail
v=parenc(11,8); assert(~isempty(v)) assert(v==36)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test27 (line 1) v=parenc(11,8);

28   Fail
v=parenc(17,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test28 (line 1) v=parenc(17,1);

29   Fail
v=parenc(4,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test29 (line 1) v=parenc(4,2);

30   Fail
v=parenc(1,6); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test30 (line 1) v=parenc(1,6);

31   Fail
v=parenc(5,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test31 (line 1) v=parenc(5,4);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test32 (line 1) v=parenc(1,1);

33   Fail
v=parenc(7,13); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test33 (line 1) v=parenc(7,13);

34   Fail
v=parenc(6,12); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test34 (line 1) v=parenc(6,12);

35   Fail
v=parenc(15,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test35 (line 1) v=parenc(15,2);

36   Fail
v=parenc(14,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test36 (line 1) v=parenc(14,2);

37   Fail
v=parenc(12,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test37 (line 1) v=parenc(12,1);

38   Fail
v=parenc(4,15); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test38 (line 1) v=parenc(4,15);

39   Fail
v=parenc(12,7); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test39 (line 1) v=parenc(12,7);

40   Fail
v=parenc(5,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test40 (line 1) v=parenc(5,1);

41   Fail
v=parenc(19,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test41 (line 1) v=parenc(19,1);

42   Fail
v=parenc(6,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test42 (line 1) v=parenc(6,5);

43   Fail
v=parenc(11,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test43 (line 1) v=parenc(11,5);

44   Fail
v=parenc(8,12); assert(~isempty(v)) assert(v==36)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test44 (line 1) v=parenc(8,12);

45   Fail
v=parenc(18,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test45 (line 1) v=parenc(18,2);

46   Fail
v=parenc(18,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test46 (line 1) v=parenc(18,1);

47   Fail
v=parenc(13,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test47 (line 1) v=parenc(13,4);

48   Fail
v=parenc(3,6); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test48 (line 1) v=parenc(3,6);

49   Fail
v=parenc(6,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test49 (line 1) v=parenc(6,1);

50   Fail
v=parenc(3,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test50 (line 1) v=parenc(3,3);

51   Fail
v=parenc(19,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test51 (line 1) v=parenc(19,1);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test52 (line 1) v=parenc(9,11);

53   Fail
v=parenc(10,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test53 (line 1) v=parenc(10,1);

54   Fail
v=parenc(0,11); assert(~isempty(v)) assert(v==0)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test54 (line 1) v=parenc(0,11);

55   Fail
v=parenc(11,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test55 (line 1) v=parenc(11,3);

56   Fail
v=parenc(3,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test56 (line 1) v=parenc(3,2);

57   Fail
v=parenc(18,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test57 (line 1) v=parenc(18,2);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test58 (line 1) v=parenc(1,0);

59   Fail
v=parenc(9,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test59 (line 1) v=parenc(9,1);

60   Fail
v=parenc(1,19); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test60 (line 1) v=parenc(1,19);

61   Fail
v=parenc(4,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test61 (line 1) v=parenc(4,3);

62   Fail
v=parenc(13,7); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test62 (line 1) v=parenc(13,7);

63   Fail
v=parenc(8,6); assert(~isempty(v)) assert(v==21)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test63 (line 1) v=parenc(8,6);

64   Fail
v=parenc(7,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test64 (line 1) v=parenc(7,1);

65   Fail
v=parenc(16,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test65 (line 1) v=parenc(16,2);

66   Fail
v=parenc(16,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test66 (line 1) v=parenc(16,4);

67   Fail
v=parenc(7,8); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test67 (line 1) v=parenc(7,8);

68   Fail
v=parenc(13,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test68 (line 1) v=parenc(13,3);

69   Fail
v=parenc(4,14); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test69 (line 1) v=parenc(4,14);

70   Fail
v=parenc(7,8); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test70 (line 1) v=parenc(7,8);

71   Fail
v=parenc(9,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test71 (line 1) v=parenc(9,5);

72   Fail
v=parenc(4,7); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test72 (line 1) v=parenc(4,7);

73   Fail
v=parenc(12,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test73 (line 1) v=parenc(12,2);

74   Fail
v=parenc(10,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test74 (line 1) v=parenc(10,1);

75   Fail
v=parenc(17,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test75 (line 1) v=parenc(17,3);

76   Fail
v=parenc(4,13); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test76 (line 1) v=parenc(4,13);

77   Fail
v=parenc(11,1); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test77 (line 1) v=parenc(11,1);

78   Fail
v=parenc(10,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test78 (line 1) v=parenc(10,5);

79   Fail
v=parenc(7,7); assert(~isempty(v)) assert(v==28)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test79 (line 1) v=parenc(7,7);

80   Fail
v=parenc(6,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test80 (line 1) v=parenc(6,4);

81   Fail
v=parenc(5,13); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test81 (line 1) v=parenc(5,13);

82   Fail
v=parenc(10,10); assert(~isempty(v)) assert(v==55)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test82 (line 1) v=parenc(10,10);

83   Fail
v=parenc(14,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test83 (line 1) v=parenc(14,3);

84   Fail
v=parenc(8,4); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test84 (line 1) v=parenc(8,4);

85   Fail
v=parenc(14,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test85 (line 1) v=parenc(14,5);

86   Fail
v=parenc(0,20); assert(~isempty(v)) assert(v==0)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test86 (line 1) v=parenc(0,20);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test87 (line 1) v=parenc(0,1);

88   Fail
v=parenc(1,10); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test88 (line 1) v=parenc(1,10);

89   Fail
v=parenc(13,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test89 (line 1) v=parenc(13,3);

90   Fail
v=parenc(0,9); assert(~isempty(v)) assert(v==0)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test90 (line 1) v=parenc(0,9);

91   Fail
v=parenc(1,17); assert(~isempty(v)) assert(v==1)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test91 (line 1) v=parenc(1,17);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test92 (line 1) v=parenc(0,2);

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

Undefined function 'parenc' for input arguments of type 'double'. Error in Test93 (line 1) v=parenc(2,0);

94   Fail
v=parenc(4,12); assert(~isempty(v)) assert(v==10)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test94 (line 1) v=parenc(4,12);

95   Fail
v=parenc(11,9); assert(~isempty(v)) assert(v==45)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test95 (line 1) v=parenc(11,9);

96   Fail
v=parenc(18,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test96 (line 1) v=parenc(18,2);

97   Fail
v=parenc(15,3); assert(~isempty(v)) assert(v==6)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test97 (line 1) v=parenc(15,3);

98   Fail
v=parenc(16,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test98 (line 1) v=parenc(16,2);

99   Fail
v=parenc(17,2); assert(~isempty(v)) assert(v==3)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test99 (line 1) v=parenc(17,2);

100   Fail
v=parenc(14,5); assert(~isempty(v)) assert(v==15)

Undefined function 'parenc' for input arguments of type 'double'. Error in Test100 (line 1) v=parenc(14,5);

Suggested Problems

More from this Author241

Community Treasure Hunt

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

Start Hunting!