{"group":{"id":1,"name":"Community","lockable":false,"created_at":"2012-01-18T18:02:15.000Z","updated_at":"2026-04-06T14:01:22.000Z","description":"Problems submitted by members of the MATLAB Central community.","is_default":true,"created_by":161519,"badge_id":null,"featured":false,"trending":false,"solution_count_in_trending_period":0,"trending_last_calculated":"2026-04-06T00:00:00.000Z","image_id":null,"published":true,"community_created":false,"status_id":2,"is_default_group_for_player":false,"deleted_by":null,"deleted_at":null,"restored_by":null,"restored_at":null,"description_opc":null,"description_html":null,"published_at":null},"problems":[{"id":553,"title":"How to multiply?","description":"Imagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\r\nand competing for the highly prestigious post of,\r\nChief Comptroller of Ylpitlum Corporation.\r\nYou are being tested via MATLAB Cody for multiplication of two positive integers X and Y,\r\nboth are fortunately in decimal system, and only a few dozen digits or less,\r\nand delivered as ASCII strings.\r\nPlease output the result Z in similar style.\r\nPlease adopt a general strategy, as X and Y may be changed later.\r\nPlease rename the function Z = ylpitlum(X,Y).\r\nFunction Template:\r\nfunction Z = ylpitlum(X,Y)\r\n   %  098765432109876543210987654321098765432109876543210987654321\r\n   X='170000000000000000000000000000';\r\n   Y='190000000000000000000000000000';\r\n   Z='32300000000000000000000000000000000000000000000000000000000';\r\nend","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 346.933px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 173.467px; transform-origin: 407px 173.467px; vertical-align: baseline; \"\u003e\u003cul style=\"block-size: 204.333px; counter-reset: list-item 0; font-family: Helvetica, Arial, sans-serif; list-style-type: square; margin-block-end: 20px; margin-block-start: 10px; margin-bottom: 20px; margin-top: 10px; perspective-origin: 391px 102.167px; transform-origin: 391px 102.167px; margin-top: 10px; margin-bottom: 20px; \"\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 254.5px 8px; transform-origin: 254.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eImagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 151.5px 8px; transform-origin: 151.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eand competing for the highly prestigious post of,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 131px 8px; transform-origin: 131px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eChief Comptroller of Ylpitlum Corporation.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 76.5px 8px; transform-origin: 76.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eYou are being tested via\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 2px 8px; transform-origin: 2px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e \u003c/span\u003e\u003c/span\u003e\u003ca target='_blank' href = \"/#null\"\u003e\u003cspan style=\"\"\u003e\u003cspan style=\"\"\u003eMATLAB Cody\u003c/span\u003e\u003c/span\u003e\u003c/a\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 154.5px 8px; transform-origin: 154.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e for multiplication of two positive integers X and Y,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 233.5px 8px; transform-origin: 233.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eboth are fortunately in decimal system, and only a few dozen digits or less,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 96.5px 8px; transform-origin: 96.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eand delivered as ASCII strings.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 129px 8px; transform-origin: 129px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease output the result Z in similar style.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 210.5px 8px; transform-origin: 210.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease adopt a general strategy, as X and Y may be changed later.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 141.5px 8px; transform-origin: 141.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease rename the function Z = ylpitlum(X,Y).\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 60px 8px; transform-origin: 60px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eFunction Template:\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003c/ul\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 122.6px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 61.3px; transform-origin: 404px 61.3px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 104px 8.5px; tab-size: 4; transform-origin: 104px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"border-block-end-color: rgb(14, 0, 255); border-block-start-color: rgb(14, 0, 255); border-bottom-color: rgb(14, 0, 255); border-inline-end-color: rgb(14, 0, 255); border-inline-start-color: rgb(14, 0, 255); border-left-color: rgb(14, 0, 255); border-right-color: rgb(14, 0, 255); border-top-color: rgb(14, 0, 255); caret-color: rgb(14, 0, 255); color: rgb(14, 0, 255); column-rule-color: rgb(14, 0, 255); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(14, 0, 255); perspective-origin: 36px 8.5px; text-decoration: none; text-decoration-color: rgb(14, 0, 255); text-emphasis-color: rgb(14, 0, 255); transform-origin: 36px 8.5px; \"\u003efunction \u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 68px 8.5px; transform-origin: 68px 8.5px; \"\u003eZ = ylpitlum(X,Y)\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 264px 8.5px; tab-size: 4; transform-origin: 264px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 12px 8.5px; transform-origin: 12px 8.5px; \"\u003e   \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(2, 128, 9); border-block-start-color: rgb(2, 128, 9); border-bottom-color: rgb(2, 128, 9); border-inline-end-color: rgb(2, 128, 9); border-inline-start-color: rgb(2, 128, 9); border-left-color: rgb(2, 128, 9); border-right-color: rgb(2, 128, 9); border-top-color: rgb(2, 128, 9); caret-color: rgb(2, 128, 9); color: rgb(2, 128, 9); column-rule-color: rgb(2, 128, 9); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(2, 128, 9); perspective-origin: 252px 8.5px; text-decoration: none; text-decoration-color: rgb(2, 128, 9); text-emphasis-color: rgb(2, 128, 9); transform-origin: 252px 8.5px; \"\u003e%  098765432109876543210987654321098765432109876543210987654321\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 152px 8.5px; tab-size: 4; transform-origin: 152px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   X=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 128px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 128px 8.5px; \"\u003e'170000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 152px 8.5px; tab-size: 4; transform-origin: 152px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   Y=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 128px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 128px 8.5px; \"\u003e'190000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 268px 8.5px; tab-size: 4; transform-origin: 268px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   Z=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 244px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 244px 8.5px; \"\u003e'32300000000000000000000000000000000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 12px 8.5px; tab-size: 4; transform-origin: 12px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"border-block-end-color: rgb(14, 0, 255); border-block-start-color: rgb(14, 0, 255); border-bottom-color: rgb(14, 0, 255); border-inline-end-color: rgb(14, 0, 255); border-inline-start-color: rgb(14, 0, 255); border-left-color: rgb(14, 0, 255); border-right-color: rgb(14, 0, 255); border-top-color: rgb(14, 0, 255); caret-color: rgb(14, 0, 255); color: rgb(14, 0, 255); column-rule-color: rgb(14, 0, 255); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(14, 0, 255); text-decoration: none; text-decoration-color: rgb(14, 0, 255); text-emphasis-color: rgb(14, 0, 255); \"\u003eend\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function Z = ylpitlum(X,Y)\r\n   %  098765432109876543210987654321098765432109876543210987654321\r\n   X='170000000000000000000000000000';\r\n   Y='190000000000000000000000000000';\r\n   Z='32300000000000000000000000000000000000000000000000000000000';\r\nend","test_suite":"%%\r\nX='170000000000000000000000000000';\r\nY='190000000000000000000000000000';\r\nZ='32300000000000000000000000000000000000000000000000000000000';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n%%\r\nX='235711131719';\r\nY='232931374143475359';\r\nZ='54904517812220391149679812121';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n%%\r\nX='7657534422342987897979879745232234';\r\nY='9878765654343431233130980808776767';\r\nZ='75646988048394475543709477144832189651639589891288011407029878707478';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":2,"created_by":166,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":82,"test_suite_updated_at":"2021-11-28T17:15:31.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2012-04-03T06:24:52.000Z","updated_at":"2026-02-10T19:25:06.000Z","published_at":"2012-04-03T06:24:52.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eImagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eand competing for the highly prestigious post of,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eChief Comptroller of Ylpitlum Corporation.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eYou are being tested via\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eMATLAB Cody\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e for multiplication of two positive integers X and Y,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eboth are fortunately in decimal system, and only a few dozen digits or less,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eand delivered as ASCII strings.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease output the result Z in similar style.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease adopt a general strategy, as X and Y may be changed later.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease rename the function Z = ylpitlum(X,Y).\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eFunction Template:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[function Z = ylpitlum(X,Y)\\n   %  098765432109876543210987654321098765432109876543210987654321\\n   X='170000000000000000000000000000';\\n   Y='190000000000000000000000000000';\\n   Z='32300000000000000000000000000000000000000000000000000000000';\\nend]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":61147,"title":"Determine whether a number is a repfigit number","description":"A sequence of numbers is constructed from a number  with the following steps:\r\nList the  digits of .\r\nCompute the ()st term as the sum of the digits of . \r\nCompute the remaining terms as the sum of the previous  terms. \r\nA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \r\nWrite a function to determine whether the input number (given as a character string) is a repfigit number. ","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.44px; min-height: 0px; white-space: normal; color: rgb(33, 33, 33); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: none; white-space: normal; \"\u003e\u003cdiv style=\"block-size: 205.312px; display: block; min-width: 0px; padding-block-start: 0px; padding-inline-start: 2px; padding-left: 2px; padding-top: 0px; perspective-origin: 408px 102.65px; transform-origin: 408px 102.656px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eA sequence of numbers is constructed from a number \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e with the following steps:\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003col style=\"block-size: 61.3125px; font-family: Helvetica, Arial, sans-serif; list-style-type: decimal; margin-block-end: 20px; margin-block-start: 10px; margin-bottom: 20px; margin-top: 10px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 391px 30.65px; transform-origin: 391px 30.6562px; margin-top: 10px; margin-bottom: 20px; \"\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eList the \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e digits of \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eCompute the (\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"vertical-align:-5px\"\u003e\u003cimg src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEYAAAAkCAYAAAA0EkzVAAADuElEQVR4AeyYTUhUURTH58ORJitoDKWwUcfJatCipuhrYyktCzcFbpI+NhEUtCho0SLaJbmvKIiiZQRKi7KBCEKYChQNcr5sIEY0CR0Gna9+R57iOO85k6QNryfn/8695565757/PffjaTEZf6oMGMSo0mIyGcQYxGgwoGE2MsYgRoMBDbORMf87MTU1NXaXy3W+vr6+v7a2dqsGHwtm3WfMPCHl5eXfstnsI+BYiH6Zgq6JITPabTbbC+LfCSHr0UVLSRBTXV1dUVdX95w0D5DubUWPfnlHc0VFRU8oFDodDAZv4toDipaSIKaystLMiKuBi5m1o/+GZIeGhmaVjrLoNChaSoKYoke7ho4GMRpk5xHj9XptrPMdrPlzrPmHYJh6N7+XdLdSP0PbIDoFBmhrpm315B/1nEfM+Pi4m3XeaTab7zCmC8CVyWReezwe2SAfUL9L2xTaCprwvYjWneQRE4lEhkOh0C0i7QMiozy+JhKJLghJJ5PJPRaL5Qq2SSAyLQ+9IY8YCdDpdG5G7wIiH3ichZSMw+G4HI1GE6lUqgrbJjBLxrxH605UieFS5CLSRiBHnBVS2sFtv9+fxGYiY/ahZSmNQtIA5YLCfvQEZNVANk7R/wmlk1dqPortZ0NDg1fxW1WlSkw6nT7AWyVrUKaTZMXVQCAwJhU23nXoI8CEvd/tdsekrDfkEdPS0lLG7LUqgUq23A+Hw/1K3cRGvI3yXiCZ0+vz+VJSLgT2rU5gVoPdbt8IyX1KH6fUfBSbgwnyK36rqvKIGRkZkRuoLBV58SADfkwhC+bEarU2URByfpBZnyjrUvKI4St0N5E6gSyVp8zU0qUi2WSFsGG+Rb6Lnx6RRwwBHyfQcjBGdvSiF0Q5rQ6JgeX2kW+RaS54rWyIx8SmJ+QQwyVuA8QclgAJ3D8zMxOQ8jwWnVaztL+DkKP4XwKD8z560TnExOPx7QQsS0k2WZ/cWRYHqmy8c6cV5Q5wj/YbfNb/QpesNDY2bmFwHmAivo1lZWWVUl4OOcSwdPbjLP/2m6T8lnKOYPtMx7LhWtBOMqWDPSiS41RCFZZ5M+jmrvWFYR0EIlUcGi+5F3XR1iansBiXIocYZv4ZgcqRqnoscmJF8fHiYwNtHOPhpR2upD4xMSGnnmzyQQhPrKQPtd8w1gFwDdQwXolrDozbTf069jda140cYtQ6XwtbLBaLM1jJvgYZ7Fq8s9A7/oCYQl3pq90gRmM+DWIMYjQY0DAbGWMQo8GAhtnIGA1ifgMAAP//+n07nwAAAAZJREFUAwAv1IFYg5s5JgAAAABJRU5ErkJggg==\" width=\"35\" height=\"18\" style=\"width: 35px; height: 18px;\"\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e)st term as the sum of the digits of \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e. \u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eCompute the remaining terms as the sum of the previous \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e terms. \u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003c/ol\u003e\u003cdiv style=\"block-size: 63px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 31.5px; text-align: left; transform-origin: 384px 31.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function to determine whether the input number (given as a character string) is a repfigit number. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function tf = is_repfigit(x)\r\n   tf = isequal(sum(x),x);\r\nend","test_suite":"%%\r\nassert(all(~arrayfun(@is_repfigit,'0123456789')))\r\n\r\n%%\r\nassert(is_repfigit('14'))\r\n\r\n%%\r\nassert(~is_repfigit('25'))\r\n\r\n%%\r\nassert(~is_repfigit('52'))\r\n\r\n%%\r\nassert(is_repfigit('197'))\r\n\r\n%%\r\nassert(is_repfigit('742'))\r\n\r\n%%\r\nassert(is_repfigit('7909'))\r\n\r\n%%\r\nassert(~is_repfigit(num2str(8000+randi(23000))))\r\n\r\n%%\r\nassert(is_repfigit('86935'))\r\n\r\n%%\r\nassert(~is_repfigit('104057'))\r\n\r\n%%\r\nassert(is_repfigit('355419'))\r\n\r\n%%\r\nassert(~is_repfigit('33455755'))\r\n\r\n%%\r\nassert(~is_repfigit('7916837'))\r\n\r\n%%\r\nassert(is_repfigit('96189170155'))\r\n\r\n%%\r\nassert(is_repfigit('3756915124022254'))\r\n\r\n%%\r\nassert(is_repfigit('26842994422637112523337'))\r\n\r\n%%\r\nassert(~is_repfigit('19876234926457288521947945'))\r\n\r\n%%\r\nassert(is_repfigit('154140275428339949899922650'))\r\n\r\n%%\r\nassert(is_repfigit('70267375510207885242218837404'))\r\n\r\n%%\r\nfiletext = fileread('is_repfigit.m');\r\nillegal = contains(filetext, 'oeis') || contains(filetext, 'read'); \r\nassert(~illegal)","published":true,"deleted":false,"likes_count":0,"comments_count":3,"created_by":46909,"edited_by":46909,"edited_at":"2026-01-03T14:04:54.000Z","deleted_by":null,"deleted_at":null,"solvers_count":6,"test_suite_updated_at":"2026-01-03T14:04:54.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2026-01-03T04:37:28.000Z","updated_at":"2026-02-26T10:35:45.000Z","published_at":"2026-01-03T04:37:35.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA sequence of numbers is constructed from a number \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e with the following steps:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eList the \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e digits of \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCompute the (\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en+1\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e)st term as the sum of the digits of \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCompute the remaining terms as the sum of the previous \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e terms. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function to determine whether the input number (given as a character string) is a repfigit number. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":54355,"title":"Compute a determinant","description":"Write a function to compute the determinant of an  x  matrix with diagonal entries equal to an integer  and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. ","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 84px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 42px; transform-origin: 407px 42px; vertical-align: baseline; \"\u003e\u003cdiv style=\"font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 42px; text-align: left; transform-origin: 384px 42px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 155.058px 7.50833px; transform-origin: 155.058px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function to compute the determinant of an \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 7.38333px 7.50833px; transform-origin: 7.38333px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e x \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 148.6px 7.50833px; transform-origin: 148.6px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e matrix with diagonal entries equal to an integer \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003em\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 55.5417px 7.50833px; transform-origin: 55.5417px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function d = det1m1(m,n)\r\n%  m = value of the diagonal elements\r\n%  n = number of rows (and number of columns) in the matrix\r\n  d = det(m*ones(n)); \r\nend","test_suite":"%%\r\nm = 3;\r\nn = 4;\r\nd_correct = '48';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 6;\r\nd_correct = '2187';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 8;\r\nd_correct = '196608';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 10;\r\nd_correct = '29296875';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 12;\r\nd_correct = '6530347008';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 14;\r\nd_correct = '2034669218547';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 16;\r\nd_correct = '844424930131968';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 18;\r\nd_correct = '450283905890997363';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 3;\r\nn = 11;\r\nd_correct = '13312';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 23;\r\nd_correct = '815907549834';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 35;\r\nd_correct = '11510768301994760208384';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 47;\r\nd_correct = '7389644451905041933059692382812500';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 59;\r\nd_correct = '88244140798466714911277191605426368090776535040';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 61;\r\nd_correct = '34545486530294388841908797440350722120525547688848068';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 73;\r\nd_correct = '8530295625153132122531360242377305017830502727444478011599189180416';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 85;\r\nd_correct = '13474065260887738958592269707715179680415947079403261118461216165154684923152533534';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 3;\r\nn = 102;\r\nd_correct = '263671324847471715511314266718208';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 204;\r\nd_correct = '1484516583827264085834448808857972334348585766879821838001899461159787931647377900755616082956921589';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 306;\r\nd_correct = '1317222222185582404750178752250122195777390931963039169534621462737000828454913561993123005617768628458845537125891322518059516757378713953735609547341136632820701551671775183198685757440';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 408;\r\nd_correct = '124951598502560034896394269652129946331757853618449267769253601154315933731589398710022481465344299103361544144970312116700012143186237553149274793353112011968516101168494470432107221238134466674961271002967647750880848795089462041698055925535390010827629936329685733653604984283447265625';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 131;\r\nd_correct = '19787144122548913527680843308148452884189065069542617898413668362936707627112683949809939148161587085312';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 253;\r\nd_correct = '239706290717189721123302390680335669996774024601257391994275410885640688563963931353802954101567887964817392073386621397628285918677445066165167532386216609465769894926518235382109183970227816546732204593629492112260';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 275;\r\nd_correct = '7914853329031654317236831887919901653197511900121381509601494400150421009291867067475308053933954912350106192489235274200248351166261489849830021845471460969340960380037223657169438239256397454763033517899984282261414401045612047034322789796027564032';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 299;\r\nd_correct = '71255522567471178828644915252719777959098869895626873084614916973200846625340632259847469229339030912305938532041146325885842950734329231286703535740125377847932872013226581480729929782019398917380980682083141726871697818941018246912605765632004456807782308943877135926039567345812106868';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nmn = [4 30; 5 23; 6 21; 7 18; 8 15];\r\ns_correct = [101 97 115 94 111];\r\nfor k = randi(5,[1 3])\r\n    s = sum(factor(str2num(det1m1(mn(k,1),mn(k,2)))));\r\n    assert(isequal(s,s_correct(k)));\r\nend\r\n\r\n%%\r\nfiletext = fileread('det1m1.m');\r\nillegal = contains(filetext, 'assignin') || contains(filetext, 'assert') || contains(filetext, 'java') || contains(filetext, 'py'); \r\nassert(~illegal)","published":true,"deleted":false,"likes_count":0,"comments_count":0,"created_by":46909,"edited_by":46909,"edited_at":"2022-04-24T23:49:15.000Z","deleted_by":null,"deleted_at":null,"solvers_count":13,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2022-04-23T21:41:11.000Z","updated_at":"2026-02-01T14:01:13.000Z","published_at":"2022-04-23T21:51:12.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function to compute the determinant of an \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e x \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e matrix with diagonal entries equal to an integer \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"m\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003em\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":54280,"title":"N-th Digit of all Write-Down Numbers","description":"Write-Down Numbers are: 123456789101112131415161718192021222324252627282930...\r\nWhat is the N'th digit (where N is represented as a character array) ?\r\nSee problem #54265 as reference.","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.44px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: none solid rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 81px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 40.5px; transform-origin: 407px 40.5px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eWrite-Down Numbers are: 123456789101112131415161718192021222324252627282930...\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eWhat is the N'th digit (where N is represented as a character array) ?\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eSee problem #54265 as reference.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function d = writeDownNth(N)\r\n  d=5;\r\nend","test_suite":"%%\r\nd=writeDownNth('9');\r\nd_correct=9;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('10');\r\nd_correct=1;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('11');\r\nd_correct=0;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('190');\r\nd_correct=1;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('191');\r\nd_correct=0;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('1001');\r\nd_correct=7;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('10000001');\r\nd_correct=3\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(1);\r\nk=repmat('012345679',1,10000);\r\nd=zeros(1,20);\r\nfor n=1:20\r\n   r=randperm(randi(9900)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[3,0,6,0,8,0,5,1,9,0,2,5,3,8,6,0,4,3,3,8];\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(10);\r\nk=repmat('012345679',1,100000);\r\nd=zeros(1,2);\r\nfor n=1:2\r\n   r=randperm(randi(99000)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[4,7];\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(100);\r\nk=repmat('012345679',1,1000);\r\nd=zeros(1,2);\r\nfor n=1:50\r\n   r=randperm(randi(900)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[5,5,6,6,3,9,4,4,2,6,0,1,2,9,6,3,1,3,4,2,4,5,8,6,7,3,4,7,5,0,7,2,7,1,3,1,4,6,1,7,4,7,5,4,1,1,8,1,3,3];\r\nassert(isequal(d,d_correct))\r\n\r\n","published":true,"deleted":false,"likes_count":1,"comments_count":0,"created_by":145982,"edited_by":145982,"edited_at":"2022-04-14T18:31:45.000Z","deleted_by":null,"deleted_at":null,"solvers_count":3,"test_suite_updated_at":"2022-04-14T18:31:45.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2022-04-13T17:50:59.000Z","updated_at":"2022-04-14T18:31:45.000Z","published_at":"2022-04-13T17:50:59.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite-Down Numbers are: 123456789101112131415161718192021222324252627282930...\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWhat is the N'th digit (where N is represented as a character array) ?\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSee problem #54265 as reference.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":44955,"title":"Spell the number","description":"Using the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places.  The function should be able to accept spaces, commas and leading zeros.  Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\r\n\r\nExamples:\r\n\r\n  '10007.76'     should return 'Ten thousand and seven point seven six'\r\n  '001102.34'    should return 'One thousand one hundred and two point three four'\r\n  '.4'           should return 'Zero point four'\r\n  '4.'           should return 'Four'\r\n  '0.' and '.'   should return 'Zero'\r\n  '340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine'\r\n\r\n\r\nIn the British short scale notation:\r\n\r\n  1 Hundred      = 10^2\r\n  1 Thousand     = 10^3\r\n  1 Million      = 10^6\r\n  1 Billion      = 10^9\r\n  1 Trillion     = 10^12\r\n  1 Quadrillion  = 10^15\r\n  1 Quintillion  = 10^18\r\n  1 Sextillion   = 10^21\r\n  1 Septillion   = 10^24\r\n  1 Octillion    = 10^27\r\n  1 Nonillion    = 10^30\r\n  1 Decillion    = 10^33\r\n  1 Vigintillion = 10^63\r\n  1 Centillion   = 10^303\r\n","description_html":"\u003cp\u003eUsing the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places.  The function should be able to accept spaces, commas and leading zeros.  Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\u003c/p\u003e\u003cp\u003eExamples:\u003c/p\u003e\u003cpre class=\"language-matlab\"\u003e'10007.76'     should return 'Ten thousand and seven point seven six'\r\n'001102.34'    should return 'One thousand one hundred and two point three four'\r\n'.4'           should return 'Zero point four'\r\n'4.'           should return 'Four'\r\n'0.' and '.'   should return 'Zero'\r\n'340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine'\r\n\u003c/pre\u003e\u003cp\u003eIn the British short scale notation:\u003c/p\u003e\u003cpre class=\"language-matlab\"\u003e1 Hundred      = 10^2\r\n1 Thousand     = 10^3\r\n1 Million      = 10^6\r\n1 Billion      = 10^9\r\n1 Trillion     = 10^12\r\n1 Quadrillion  = 10^15\r\n1 Quintillion  = 10^18\r\n1 Sextillion   = 10^21\r\n1 Septillion   = 10^24\r\n1 Octillion    = 10^27\r\n1 Nonillion    = 10^30\r\n1 Decillion    = 10^33\r\n1 Vigintillion = 10^63\r\n1 Centillion   = 10^303\r\n\u003c/pre\u003e","function_template":"function out_str = n2t(in_str)\r\n  out_str = in_str;\r\nend","test_suite":"%%\r\nx = '0';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0.003';\r\ny_correct = 'Zero point zero zero three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0.';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '.343';\r\ny_correct = 'Zero point three four three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n%%\r\nx = '.';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx='23000000011.2330';\r\ny_correct = 'Twenty three billion and eleven point two three three zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '1,700,343.04014';\r\ny_correct = 'One million seven hundred thousand three hundred and forty three point zero four zero one four';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '4,003,900,030,001';\r\ny_correct = 'Four trillion three billion nine hundred million thirty thousand and one';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '50506';\r\ny_correct = 'Fifty thousand five hundred and six';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '5001000';\r\ny_correct = 'Five million one thousand';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '101000';\r\ny_correct = 'One hundred and one thousand';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '100003.0000341';\r\ny_correct = 'One hundred thousand and three point zero zero zero zero three four one';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '3.14159265358979';\r\ny_correct = 'Three point one four one five nine two six five three five eight nine seven nine';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0497, 367, 158, 401, 387, 490, 191, 320, 142.72931574943292322499550584316';\r\ny_correct = 'Four hundred and ninety seven septillion three hundred and sixty seven sextillion one hundred and fifty eight quintillion four hundred and one quadrillion three hundred and eighty seven trillion four hundred and ninety billion one hundred and ninety one million three hundred and twenty thousand one hundred and forty two point seven two nine three one five seven four nine four three two nine two three two two four nine nine five five zero five eight four three one six';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '10000000000000000000000000600000000000000000000000000000000000000';\r\ny_correct = 'Ten vigintillion six hundred thousand decillion';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n%%\r\nx = '2878366142600744685534686064407323355445697471111330511689595534';\r\ny_correct = 'Two vigintillion eight hundred and seventy eight octillion three hundred and sixty six septillion one hundred and forty two sextillion six hundred quintillion seven hundred and forty four quadrillion six hundred and eighty five trillion five hundred and thirty four billion six hundred and eighty six million sixty four thousand four hundred and seven decillion three hundred and twenty three nonillion three hundred and fifty five octillion four hundred and forty five septillion six hundred and ninety seven sextillion four hundred and seventy one quintillion one hundred and eleven quadrillion three hundred and thirty trillion five hundred and eleven billion six hundred and eighty nine million five hundred and ninety five thousand five hundred and thirty four';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '34000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001.580023';\r\ny_correct = 'Thirty four centillion and one point five eight zero zero two three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nfiletext = fileread('n2t.m');\r\nassert(isempty(strfind(filetext, 'regexp')));\r\nassert(isempty(strfind(filetext, 'assert')));\r\nassert(isempty(strfind(filetext, 'eval'))) \r\nassert(isempty(strfind(filetext, '!'))) \r\nassert(isempty(strfind(filetext, 'eighty seven trillion four'))) \r\nassert(isempty(strfind(filetext, 'three point zero four zero one four'))) \r\nassert(~isempty(strfind(filetext, 'three'))) \r\nassert(~isempty(strfind(filetext, 'n2t'))) \r\nassert(isempty(dir ('assert.m')))\r\nassert(isempty(dir ('fileread.m')))\r\nassert(isempty(dir ('isempty.m')))\r\n","published":true,"deleted":false,"likes_count":1,"comments_count":1,"created_by":310490,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":4,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2019-08-20T13:01:17.000Z","updated_at":"2019-08-22T07:17:53.000Z","published_at":"2019-08-22T07:17:53.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eUsing the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places. The function should be able to accept spaces, commas and leading zeros. Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eExamples:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA['10007.76'     should return 'Ten thousand and seven point seven six'\\n'001102.34'    should return 'One thousand one hundred and two point three four'\\n'.4'           should return 'Zero point four'\\n'4.'           should return 'Four'\\n'0.' and '.'   should return 'Zero'\\n'340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine']]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn the British short scale notation:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[1 Hundred      = 10^2\\n1 Thousand     = 10^3\\n1 Million      = 10^6\\n1 Billion      = 10^9\\n1 Trillion     = 10^12\\n1 Quadrillion  = 10^15\\n1 Quintillion  = 10^18\\n1 Sextillion   = 10^21\\n1 Septillion   = 10^24\\n1 Octillion    = 10^27\\n1 Nonillion    = 10^30\\n1 Decillion    = 10^33\\n1 Vigintillion = 10^63\\n1 Centillion   = 10^303]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"}],"problem_search":{"errors":[],"problems":[{"id":553,"title":"How to multiply?","description":"Imagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\r\nand competing for the highly prestigious post of,\r\nChief Comptroller of Ylpitlum Corporation.\r\nYou are being tested via MATLAB Cody for multiplication of two positive integers X and Y,\r\nboth are fortunately in decimal system, and only a few dozen digits or less,\r\nand delivered as ASCII strings.\r\nPlease output the result Z in similar style.\r\nPlease adopt a general strategy, as X and Y may be changed later.\r\nPlease rename the function Z = ylpitlum(X,Y).\r\nFunction Template:\r\nfunction Z = ylpitlum(X,Y)\r\n   %  098765432109876543210987654321098765432109876543210987654321\r\n   X='170000000000000000000000000000';\r\n   Y='190000000000000000000000000000';\r\n   Z='32300000000000000000000000000000000000000000000000000000000';\r\nend","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 346.933px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 173.467px; transform-origin: 407px 173.467px; vertical-align: baseline; \"\u003e\u003cul style=\"block-size: 204.333px; counter-reset: list-item 0; font-family: Helvetica, Arial, sans-serif; list-style-type: square; margin-block-end: 20px; margin-block-start: 10px; margin-bottom: 20px; margin-top: 10px; perspective-origin: 391px 102.167px; transform-origin: 391px 102.167px; margin-top: 10px; margin-bottom: 20px; \"\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 254.5px 8px; transform-origin: 254.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eImagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 151.5px 8px; transform-origin: 151.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eand competing for the highly prestigious post of,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 131px 8px; transform-origin: 131px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eChief Comptroller of Ylpitlum Corporation.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 76.5px 8px; transform-origin: 76.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eYou are being tested via\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 2px 8px; transform-origin: 2px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e \u003c/span\u003e\u003c/span\u003e\u003ca target='_blank' href = \"/#null\"\u003e\u003cspan style=\"\"\u003e\u003cspan style=\"\"\u003eMATLAB Cody\u003c/span\u003e\u003c/span\u003e\u003c/a\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 154.5px 8px; transform-origin: 154.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e for multiplication of two positive integers X and Y,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 233.5px 8px; transform-origin: 233.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eboth are fortunately in decimal system, and only a few dozen digits or less,\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 96.5px 8px; transform-origin: 96.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eand delivered as ASCII strings.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 129px 8px; transform-origin: 129px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease output the result Z in similar style.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 210.5px 8px; transform-origin: 210.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease adopt a general strategy, as X and Y may be changed later.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 141.5px 8px; transform-origin: 141.5px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003ePlease rename the function Z = ylpitlum(X,Y).\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4333px; counter-reset: none; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2167px; text-align: left; transform-origin: 363px 10.2167px; white-space: pre-wrap; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 60px 8px; transform-origin: 60px 8px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eFunction Template:\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003c/ul\u003e\u003cdiv style=\"background-color: rgb(247, 247, 247); block-size: 122.6px; border-bottom-left-radius: 4px; border-bottom-right-radius: 4px; border-end-end-radius: 4px; border-end-start-radius: 4px; border-start-end-radius: 4px; border-start-start-radius: 4px; border-top-left-radius: 4px; border-top-right-radius: 4px; margin-block-end: 10px; margin-block-start: 10px; margin-bottom: 10px; margin-inline-end: 3px; margin-inline-start: 3px; margin-left: 3px; margin-right: 3px; margin-top: 10px; perspective-origin: 404px 61.3px; transform-origin: 404px 61.3px; margin-left: 3px; margin-top: 10px; margin-bottom: 10px; margin-right: 3px; \"\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 104px 8.5px; tab-size: 4; transform-origin: 104px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"border-block-end-color: rgb(14, 0, 255); border-block-start-color: rgb(14, 0, 255); border-bottom-color: rgb(14, 0, 255); border-inline-end-color: rgb(14, 0, 255); border-inline-start-color: rgb(14, 0, 255); border-left-color: rgb(14, 0, 255); border-right-color: rgb(14, 0, 255); border-top-color: rgb(14, 0, 255); caret-color: rgb(14, 0, 255); color: rgb(14, 0, 255); column-rule-color: rgb(14, 0, 255); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(14, 0, 255); perspective-origin: 36px 8.5px; text-decoration: none; text-decoration-color: rgb(14, 0, 255); text-emphasis-color: rgb(14, 0, 255); transform-origin: 36px 8.5px; \"\u003efunction \u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 68px 8.5px; transform-origin: 68px 8.5px; \"\u003eZ = ylpitlum(X,Y)\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 264px 8.5px; tab-size: 4; transform-origin: 264px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 12px 8.5px; transform-origin: 12px 8.5px; \"\u003e   \u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(2, 128, 9); border-block-start-color: rgb(2, 128, 9); border-bottom-color: rgb(2, 128, 9); border-inline-end-color: rgb(2, 128, 9); border-inline-start-color: rgb(2, 128, 9); border-left-color: rgb(2, 128, 9); border-right-color: rgb(2, 128, 9); border-top-color: rgb(2, 128, 9); caret-color: rgb(2, 128, 9); color: rgb(2, 128, 9); column-rule-color: rgb(2, 128, 9); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(2, 128, 9); perspective-origin: 252px 8.5px; text-decoration: none; text-decoration-color: rgb(2, 128, 9); text-emphasis-color: rgb(2, 128, 9); transform-origin: 252px 8.5px; \"\u003e%  098765432109876543210987654321098765432109876543210987654321\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 152px 8.5px; tab-size: 4; transform-origin: 152px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   X=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 128px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 128px 8.5px; \"\u003e'170000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 152px 8.5px; tab-size: 4; transform-origin: 152px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   Y=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 128px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 128px 8.5px; \"\u003e'190000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 268px 8.5px; tab-size: 4; transform-origin: 268px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 20px 8.5px; transform-origin: 20px 8.5px; \"\u003e   Z=\u003c/span\u003e\u003cspan style=\"border-block-end-color: rgb(170, 4, 249); border-block-start-color: rgb(170, 4, 249); border-bottom-color: rgb(170, 4, 249); border-inline-end-color: rgb(170, 4, 249); border-inline-start-color: rgb(170, 4, 249); border-left-color: rgb(170, 4, 249); border-right-color: rgb(170, 4, 249); border-top-color: rgb(170, 4, 249); caret-color: rgb(170, 4, 249); color: rgb(170, 4, 249); column-rule-color: rgb(170, 4, 249); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(170, 4, 249); perspective-origin: 244px 8.5px; text-decoration: none; text-decoration-color: rgb(170, 4, 249); text-emphasis-color: rgb(170, 4, 249); transform-origin: 244px 8.5px; \"\u003e'32300000000000000000000000000000000000000000000000000000000'\u003c/span\u003e\u003cspan style=\"margin-inline-end: 0px; margin-right: 0px; perspective-origin: 4px 8.5px; transform-origin: 4px 8.5px; \"\u003e;\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"background-color: rgba(0, 0, 0, 0); block-size: 20.4333px; border-bottom-left-radius: 0px; border-bottom-right-radius: 0px; border-end-end-radius: 0px; border-end-start-radius: 0px; border-inline-end-color: rgb(233, 233, 233); border-inline-end-style: solid; border-inline-end-width: 1px; border-inline-start-color: rgb(233, 233, 233); border-inline-start-style: solid; border-inline-start-width: 1px; border-left-color: rgb(233, 233, 233); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(233, 233, 233); border-right-style: solid; border-right-width: 1px; border-start-end-radius: 0px; border-start-start-radius: 0px; border-top-left-radius: 0px; border-top-right-radius: 0px; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; min-block-size: 18px; min-height: 18px; padding-inline-start: 4px; padding-left: 4px; perspective-origin: 404px 10.2167px; transform-origin: 404px 10.2167px; white-space: nowrap; \"\u003e\u003cspan style=\"block-size: auto; border-inline-end-color: rgb(0, 0, 0); border-inline-end-style: none; border-inline-end-width: 0px; border-inline-start-color: rgb(0, 0, 0); border-inline-start-style: none; border-inline-start-width: 0px; border-left-color: rgb(0, 0, 0); border-left-style: none; border-left-width: 0px; border-right-color: rgb(0, 0, 0); border-right-style: none; border-right-width: 0px; display: inline; margin-inline-end: 45px; margin-right: 45px; min-block-size: 0px; min-height: 0px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 12px 8.5px; tab-size: 4; transform-origin: 12px 8.5px; unicode-bidi: normal; white-space: pre; margin-right: 45px; \"\u003e\u003cspan style=\"border-block-end-color: rgb(14, 0, 255); border-block-start-color: rgb(14, 0, 255); border-bottom-color: rgb(14, 0, 255); border-inline-end-color: rgb(14, 0, 255); border-inline-start-color: rgb(14, 0, 255); border-left-color: rgb(14, 0, 255); border-right-color: rgb(14, 0, 255); border-top-color: rgb(14, 0, 255); caret-color: rgb(14, 0, 255); color: rgb(14, 0, 255); column-rule-color: rgb(14, 0, 255); margin-inline-end: 0px; margin-right: 0px; outline-color: rgb(14, 0, 255); text-decoration: none; text-decoration-color: rgb(14, 0, 255); text-emphasis-color: rgb(14, 0, 255); \"\u003eend\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function Z = ylpitlum(X,Y)\r\n   %  098765432109876543210987654321098765432109876543210987654321\r\n   X='170000000000000000000000000000';\r\n   Y='190000000000000000000000000000';\r\n   Z='32300000000000000000000000000000000000000000000000000000000';\r\nend","test_suite":"%%\r\nX='170000000000000000000000000000';\r\nY='190000000000000000000000000000';\r\nZ='32300000000000000000000000000000000000000000000000000000000';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n%%\r\nX='235711131719';\r\nY='232931374143475359';\r\nZ='54904517812220391149679812121';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n%%\r\nX='7657534422342987897979879745232234';\r\nY='9878765654343431233130980808776767';\r\nZ='75646988048394475543709477144832189651639589891288011407029878707478';\r\nassert(isequal(Z,ylpitlum(X,Y)))\r\n\r\n","published":true,"deleted":false,"likes_count":3,"comments_count":2,"created_by":166,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":82,"test_suite_updated_at":"2021-11-28T17:15:31.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2012-04-03T06:24:52.000Z","updated_at":"2026-02-10T19:25:06.000Z","published_at":"2012-04-03T06:24:52.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eImagine you are in 3012 Anno Domini, when everyone must learn how to multiply,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eand competing for the highly prestigious post of,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eChief Comptroller of Ylpitlum Corporation.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eYou are being tested via\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:r\u003e\u003cw:t\u003e \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:hyperlink w:docLocation=\\\"\\\"\u003e\u003cw:r\u003e\u003cw:t\u003eMATLAB Cody\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:hyperlink\u003e\u003cw:r\u003e\u003cw:t\u003e for multiplication of two positive integers X and Y,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eboth are fortunately in decimal system, and only a few dozen digits or less,\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eand delivered as ASCII strings.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease output the result Z in similar style.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease adopt a general strategy, as X and Y may be changed later.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003ePlease rename the function Z = ylpitlum(X,Y).\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"1\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eFunction Template:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[function Z = ylpitlum(X,Y)\\n   %  098765432109876543210987654321098765432109876543210987654321\\n   X='170000000000000000000000000000';\\n   Y='190000000000000000000000000000';\\n   Z='32300000000000000000000000000000000000000000000000000000000';\\nend]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":61147,"title":"Determine whether a number is a repfigit number","description":"A sequence of numbers is constructed from a number  with the following steps:\r\nList the  digits of .\r\nCompute the ()st term as the sum of the digits of . \r\nCompute the remaining terms as the sum of the previous  terms. \r\nA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \r\nWrite a function to determine whether the input number (given as a character string) is a repfigit number. ","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.44px; min-height: 0px; white-space: normal; color: rgb(33, 33, 33); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: none; white-space: normal; \"\u003e\u003cdiv style=\"block-size: 205.312px; display: block; min-width: 0px; padding-block-start: 0px; padding-inline-start: 2px; padding-left: 2px; padding-top: 0px; perspective-origin: 408px 102.65px; transform-origin: 408px 102.656px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eA sequence of numbers is constructed from a number \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e with the following steps:\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003col style=\"block-size: 61.3125px; font-family: Helvetica, Arial, sans-serif; list-style-type: decimal; margin-block-end: 20px; margin-block-start: 10px; margin-bottom: 20px; margin-top: 10px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 391px 30.65px; transform-origin: 391px 30.6562px; margin-top: 10px; margin-bottom: 20px; \"\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eList the \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e digits of \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e.\u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eCompute the (\u003c/span\u003e\u003c/span\u003e\u003cspan style=\"vertical-align:-5px\"\u003e\u003cimg src=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEYAAAAkCAYAAAA0EkzVAAADuElEQVR4AeyYTUhUURTH58ORJitoDKWwUcfJatCipuhrYyktCzcFbpI+NhEUtCho0SLaJbmvKIiiZQRKi7KBCEKYChQNcr5sIEY0CR0Gna9+R57iOO85k6QNryfn/8695565757/PffjaTEZf6oMGMSo0mIyGcQYxGgwoGE2MsYgRoMBDbORMf87MTU1NXaXy3W+vr6+v7a2dqsGHwtm3WfMPCHl5eXfstnsI+BYiH6Zgq6JITPabTbbC+LfCSHr0UVLSRBTXV1dUVdX95w0D5DubUWPfnlHc0VFRU8oFDodDAZv4toDipaSIKaystLMiKuBi5m1o/+GZIeGhmaVjrLoNChaSoKYoke7ho4GMRpk5xHj9XptrPMdrPlzrPmHYJh6N7+XdLdSP0PbIDoFBmhrpm315B/1nEfM+Pi4m3XeaTab7zCmC8CVyWReezwe2SAfUL9L2xTaCprwvYjWneQRE4lEhkOh0C0i7QMiozy+JhKJLghJJ5PJPRaL5Qq2SSAyLQ+9IY8YCdDpdG5G7wIiH3ichZSMw+G4HI1GE6lUqgrbJjBLxrxH605UieFS5CLSRiBHnBVS2sFtv9+fxGYiY/ahZSmNQtIA5YLCfvQEZNVANk7R/wmlk1dqPortZ0NDg1fxW1WlSkw6nT7AWyVrUKaTZMXVQCAwJhU23nXoI8CEvd/tdsekrDfkEdPS0lLG7LUqgUq23A+Hw/1K3cRGvI3yXiCZ0+vz+VJSLgT2rU5gVoPdbt8IyX1KH6fUfBSbgwnyK36rqvKIGRkZkRuoLBV58SADfkwhC+bEarU2URByfpBZnyjrUvKI4St0N5E6gSyVp8zU0qUi2WSFsGG+Rb6Lnx6RRwwBHyfQcjBGdvSiF0Q5rQ6JgeX2kW+RaS54rWyIx8SmJ+QQwyVuA8QclgAJ3D8zMxOQ8jwWnVaztL+DkKP4XwKD8z560TnExOPx7QQsS0k2WZ/cWRYHqmy8c6cV5Q5wj/YbfNb/QpesNDY2bmFwHmAivo1lZWWVUl4OOcSwdPbjLP/2m6T8lnKOYPtMx7LhWtBOMqWDPSiS41RCFZZ5M+jmrvWFYR0EIlUcGi+5F3XR1iansBiXIocYZv4ZgcqRqnoscmJF8fHiYwNtHOPhpR2upD4xMSGnnmzyQQhPrKQPtd8w1gFwDdQwXolrDozbTf069jda140cYtQ6XwtbLBaLM1jJvgYZ7Fq8s9A7/oCYQl3pq90gRmM+DWIMYjQY0DAbGWMQo8GAhtnIGA1ifgMAAP//+n07nwAAAAZJREFUAwAv1IFYg5s5JgAAAABJRU5ErkJggg==\" width=\"35\" height=\"18\" style=\"width: 35px; height: 18px;\"\u003e\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e)st term as the sum of the digits of \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003ex\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e. \u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003cli style=\"block-size: 20.4375px; display: list-item; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-start: 56px; margin-left: 56px; margin-top: 0px; perspective-origin: 363px 10.2125px; text-align: left; transform-origin: 363px 10.2188px; white-space-collapse: preserve; margin-left: 56px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eCompute the remaining terms as the sum of the previous \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: STIXGeneral-webfont, serif; font-style: italic; font-weight: 400; color: rgb(33, 33, 33);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-inline-start: 0px; margin-left: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e terms. \u003c/span\u003e\u003c/span\u003e\u003c/li\u003e\u003c/ol\u003e\u003cdiv style=\"block-size: 63px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 31.5px; text-align: left; transform-origin: 384px 31.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; padding-inline-start: 0px; padding-left: 0px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space-collapse: preserve; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function to determine whether the input number (given as a character string) is a repfigit number. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function tf = is_repfigit(x)\r\n   tf = isequal(sum(x),x);\r\nend","test_suite":"%%\r\nassert(all(~arrayfun(@is_repfigit,'0123456789')))\r\n\r\n%%\r\nassert(is_repfigit('14'))\r\n\r\n%%\r\nassert(~is_repfigit('25'))\r\n\r\n%%\r\nassert(~is_repfigit('52'))\r\n\r\n%%\r\nassert(is_repfigit('197'))\r\n\r\n%%\r\nassert(is_repfigit('742'))\r\n\r\n%%\r\nassert(is_repfigit('7909'))\r\n\r\n%%\r\nassert(~is_repfigit(num2str(8000+randi(23000))))\r\n\r\n%%\r\nassert(is_repfigit('86935'))\r\n\r\n%%\r\nassert(~is_repfigit('104057'))\r\n\r\n%%\r\nassert(is_repfigit('355419'))\r\n\r\n%%\r\nassert(~is_repfigit('33455755'))\r\n\r\n%%\r\nassert(~is_repfigit('7916837'))\r\n\r\n%%\r\nassert(is_repfigit('96189170155'))\r\n\r\n%%\r\nassert(is_repfigit('3756915124022254'))\r\n\r\n%%\r\nassert(is_repfigit('26842994422637112523337'))\r\n\r\n%%\r\nassert(~is_repfigit('19876234926457288521947945'))\r\n\r\n%%\r\nassert(is_repfigit('154140275428339949899922650'))\r\n\r\n%%\r\nassert(is_repfigit('70267375510207885242218837404'))\r\n\r\n%%\r\nfiletext = fileread('is_repfigit.m');\r\nillegal = contains(filetext, 'oeis') || contains(filetext, 'read'); \r\nassert(~illegal)","published":true,"deleted":false,"likes_count":0,"comments_count":3,"created_by":46909,"edited_by":46909,"edited_at":"2026-01-03T14:04:54.000Z","deleted_by":null,"deleted_at":null,"solvers_count":6,"test_suite_updated_at":"2026-01-03T14:04:54.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2026-01-03T04:37:28.000Z","updated_at":"2026-02-26T10:35:45.000Z","published_at":"2026-01-03T04:37:35.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA sequence of numbers is constructed from a number \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e with the following steps:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eList the \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e digits of \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCompute the (\u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en+1\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e)st term as the sum of the digits of \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"x\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003ex\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"ListParagraph\\\"/\u003e\u003cw:numPr\u003e\u003cw:numId w:val=\\\"2\\\"/\u003e\u003c/w:numPr\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eCompute the remaining terms as the sum of the previous \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e terms. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eA repfigit (or Keith) number is a starting number greater than 9 that reappears in the sequence. For example, starting with 14, one gets 1, 4, 5, 9, 14. Starting with 197, one gets 1, 9, 7, 17, 33, 57, 107, 197. Thus, both 14 and 197 are repfigit numbers. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function to determine whether the input number (given as a character string) is a repfigit number. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":54355,"title":"Compute a determinant","description":"Write a function to compute the determinant of an  x  matrix with diagonal entries equal to an integer  and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. ","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.4333px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 84px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 42px; transform-origin: 407px 42px; vertical-align: baseline; \"\u003e\u003cdiv style=\"font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 42px; text-align: left; transform-origin: 384px 42px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 155.058px 7.50833px; transform-origin: 155.058px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003eWrite a function to compute the determinant of an \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 7.38333px 7.50833px; transform-origin: 7.38333px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e x \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003en\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 148.6px 7.50833px; transform-origin: 148.6px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e matrix with diagonal entries equal to an integer \u003c/span\u003e\u003c/span\u003e\u003cspan style=\"font-family: \u0026quot;STIXGeneral\u0026quot;, \u0026quot;STIXGeneral-webfont\u0026quot;, serif; font-style: italic; font-weight: 400; color: rgb(0, 0, 0);\"\u003em\u003c/span\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 55.5417px 7.50833px; transform-origin: 55.5417px 7.50833px; unicode-bidi: normal; \"\u003e\u003cspan style=\"\"\u003e and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. \u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function d = det1m1(m,n)\r\n%  m = value of the diagonal elements\r\n%  n = number of rows (and number of columns) in the matrix\r\n  d = det(m*ones(n)); \r\nend","test_suite":"%%\r\nm = 3;\r\nn = 4;\r\nd_correct = '48';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 6;\r\nd_correct = '2187';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 8;\r\nd_correct = '196608';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 10;\r\nd_correct = '29296875';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 12;\r\nd_correct = '6530347008';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 14;\r\nd_correct = '2034669218547';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 16;\r\nd_correct = '844424930131968';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 18;\r\nd_correct = '450283905890997363';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 3;\r\nn = 11;\r\nd_correct = '13312';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 23;\r\nd_correct = '815907549834';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 35;\r\nd_correct = '11510768301994760208384';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 47;\r\nd_correct = '7389644451905041933059692382812500';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 59;\r\nd_correct = '88244140798466714911277191605426368090776535040';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 61;\r\nd_correct = '34545486530294388841908797440350722120525547688848068';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 73;\r\nd_correct = '8530295625153132122531360242377305017830502727444478011599189180416';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 85;\r\nd_correct = '13474065260887738958592269707715179680415947079403261118461216165154684923152533534';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 3;\r\nn = 102;\r\nd_correct = '263671324847471715511314266718208';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 4;\r\nn = 204;\r\nd_correct = '1484516583827264085834448808857972334348585766879821838001899461159787931647377900755616082956921589';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 5;\r\nn = 306;\r\nd_correct = '1317222222185582404750178752250122195777390931963039169534621462737000828454913561993123005617768628458845537125891322518059516757378713953735609547341136632820701551671775183198685757440';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 6;\r\nn = 408;\r\nd_correct = '124951598502560034896394269652129946331757853618449267769253601154315933731589398710022481465344299103361544144970312116700012143186237553149274793353112011968516101168494470432107221238134466674961271002967647750880848795089462041698055925535390010827629936329685733653604984283447265625';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 7;\r\nn = 131;\r\nd_correct = '19787144122548913527680843308148452884189065069542617898413668362936707627112683949809939148161587085312';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 8;\r\nn = 253;\r\nd_correct = '239706290717189721123302390680335669996774024601257391994275410885640688563963931353802954101567887964817392073386621397628285918677445066165167532386216609465769894926518235382109183970227816546732204593629492112260';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 9;\r\nn = 275;\r\nd_correct = '7914853329031654317236831887919901653197511900121381509601494400150421009291867067475308053933954912350106192489235274200248351166261489849830021845471460969340960380037223657169438239256397454763033517899984282261414401045612047034322789796027564032';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nm = 10;\r\nn = 299;\r\nd_correct = '71255522567471178828644915252719777959098869895626873084614916973200846625340632259847469229339030912305938532041146325885842950734329231286703535740125377847932872013226581480729929782019398917380980682083141726871697818941018246912605765632004456807782308943877135926039567345812106868';\r\nassert(strcmp(det1m1(m,n),d_correct))\r\n\r\n%%\r\nmn = [4 30; 5 23; 6 21; 7 18; 8 15];\r\ns_correct = [101 97 115 94 111];\r\nfor k = randi(5,[1 3])\r\n    s = sum(factor(str2num(det1m1(mn(k,1),mn(k,2)))));\r\n    assert(isequal(s,s_correct(k)));\r\nend\r\n\r\n%%\r\nfiletext = fileread('det1m1.m');\r\nillegal = contains(filetext, 'assignin') || contains(filetext, 'assert') || contains(filetext, 'java') || contains(filetext, 'py'); \r\nassert(~illegal)","published":true,"deleted":false,"likes_count":0,"comments_count":0,"created_by":46909,"edited_by":46909,"edited_at":"2022-04-24T23:49:15.000Z","deleted_by":null,"deleted_at":null,"solvers_count":13,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2022-04-23T21:41:11.000Z","updated_at":"2026-02-01T14:01:13.000Z","published_at":"2022-04-23T21:51:12.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite a function to compute the determinant of an \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e x \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"n\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003en\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e matrix with diagonal entries equal to an integer \u003c/w:t\u003e\u003c/w:r\u003e\u003cw:customXml w:element=\\\"equation\\\"\u003e\u003cw:customXmlPr\u003e\u003cw:attr w:name=\\\"displayStyle\\\" w:val=\\\"false\\\"/\u003e\u003cw:attr w:name=\\\"altTextString\\\" w:val=\\\"m\\\"/\u003e\u003c/w:customXmlPr\u003e\u003cw:r\u003e\u003cw:t\u003em\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:customXml\u003e\u003cw:r\u003e\u003cw:t\u003e and other entries equal to 1. For example, a 4x4 matrix with 3s on the diagonal and 1s elsewhere has a determinant of 48, and a 6x6 matrix with 4s on the diagonal and 1s elsewhere has a determinant of 2187. Return the answer as a character string, and see the test suite for forbidden functions. \u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":54280,"title":"N-th Digit of all Write-Down Numbers","description":"Write-Down Numbers are: 123456789101112131415161718192021222324252627282930...\r\nWhat is the N'th digit (where N is represented as a character array) ?\r\nSee problem #54265 as reference.","description_html":"\u003cdiv style = \"text-align: start; line-height: 20.44px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, monospace; font-style: normal; font-size: 14px; font-weight: 400; text-decoration: none solid rgb(0, 0, 0); white-space: normal; \"\u003e\u003cdiv style=\"block-size: 81px; display: block; min-width: 0px; padding-block-start: 0px; padding-top: 0px; perspective-origin: 407px 40.5px; transform-origin: 407px 40.5px; vertical-align: baseline; \"\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eWrite-Down Numbers are: 123456789101112131415161718192021222324252627282930...\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eWhat is the N'th digit (where N is represented as a character array) ?\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003cdiv style=\"block-size: 21px; font-family: Helvetica, Arial, sans-serif; line-height: 21px; margin-block-end: 9px; margin-block-start: 2px; margin-bottom: 9px; margin-inline-end: 10px; margin-inline-start: 4px; margin-left: 4px; margin-right: 10px; margin-top: 2px; perspective-origin: 384px 10.5px; text-align: left; transform-origin: 384px 10.5px; white-space: pre-wrap; margin-left: 4px; margin-top: 2px; margin-bottom: 9px; margin-right: 10px; \"\u003e\u003cspan style=\"block-size: auto; display: inline; margin-block-end: 0px; margin-block-start: 0px; margin-bottom: 0px; margin-inline-end: 0px; margin-inline-start: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; perspective-origin: 0px 0px; transform-origin: 0px 0px; \"\u003e\u003cspan style=\"\"\u003eSee problem #54265 as reference.\u003c/span\u003e\u003c/span\u003e\u003c/div\u003e\u003c/div\u003e\u003c/div\u003e","function_template":"function d = writeDownNth(N)\r\n  d=5;\r\nend","test_suite":"%%\r\nd=writeDownNth('9');\r\nd_correct=9;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('10');\r\nd_correct=1;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('11');\r\nd_correct=0;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('190');\r\nd_correct=1;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('191');\r\nd_correct=0;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('1001');\r\nd_correct=7;\r\nassert(isequal(d,d_correct))\r\n%%\r\nd=writeDownNth('10000001');\r\nd_correct=3\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(1);\r\nk=repmat('012345679',1,10000);\r\nd=zeros(1,20);\r\nfor n=1:20\r\n   r=randperm(randi(9900)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[3,0,6,0,8,0,5,1,9,0,2,5,3,8,6,0,4,3,3,8];\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(10);\r\nk=repmat('012345679',1,100000);\r\nd=zeros(1,2);\r\nfor n=1:2\r\n   r=randperm(randi(99000)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[4,7];\r\nassert(isequal(d,d_correct))\r\n%%\r\nrng(100);\r\nk=repmat('012345679',1,1000);\r\nd=zeros(1,2);\r\nfor n=1:50\r\n   r=randperm(randi(900)+20);\r\n   d(n)=writeDownNth(k(r));\r\nend\r\nd_correct=[5,5,6,6,3,9,4,4,2,6,0,1,2,9,6,3,1,3,4,2,4,5,8,6,7,3,4,7,5,0,7,2,7,1,3,1,4,6,1,7,4,7,5,4,1,1,8,1,3,3];\r\nassert(isequal(d,d_correct))\r\n\r\n","published":true,"deleted":false,"likes_count":1,"comments_count":0,"created_by":145982,"edited_by":145982,"edited_at":"2022-04-14T18:31:45.000Z","deleted_by":null,"deleted_at":null,"solvers_count":3,"test_suite_updated_at":"2022-04-14T18:31:45.000Z","rescore_all_solutions":false,"group_id":1,"created_at":"2022-04-13T17:50:59.000Z","updated_at":"2022-04-14T18:31:45.000Z","published_at":"2022-04-13T17:50:59.000Z","restored_at":null,"restored_by":null,"spam":null,"simulink":false,"admin_reviewed":false,"description_opc":"{\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWrite-Down Numbers are: 123456789101112131415161718192021222324252627282930...\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eWhat is the N'th digit (where N is represented as a character array) ?\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003cw:jc w:val=\\\"left\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eSee problem #54265 as reference.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\",\"relationship\":null}],\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"target\":\"/matlab/document.xml\",\"relationshipId\":\"rId1\"}]}"},{"id":44955,"title":"Spell the number","description":"Using the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places.  The function should be able to accept spaces, commas and leading zeros.  Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\r\n\r\nExamples:\r\n\r\n  '10007.76'     should return 'Ten thousand and seven point seven six'\r\n  '001102.34'    should return 'One thousand one hundred and two point three four'\r\n  '.4'           should return 'Zero point four'\r\n  '4.'           should return 'Four'\r\n  '0.' and '.'   should return 'Zero'\r\n  '340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine'\r\n\r\n\r\nIn the British short scale notation:\r\n\r\n  1 Hundred      = 10^2\r\n  1 Thousand     = 10^3\r\n  1 Million      = 10^6\r\n  1 Billion      = 10^9\r\n  1 Trillion     = 10^12\r\n  1 Quadrillion  = 10^15\r\n  1 Quintillion  = 10^18\r\n  1 Sextillion   = 10^21\r\n  1 Septillion   = 10^24\r\n  1 Octillion    = 10^27\r\n  1 Nonillion    = 10^30\r\n  1 Decillion    = 10^33\r\n  1 Vigintillion = 10^63\r\n  1 Centillion   = 10^303\r\n","description_html":"\u003cp\u003eUsing the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places.  The function should be able to accept spaces, commas and leading zeros.  Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\u003c/p\u003e\u003cp\u003eExamples:\u003c/p\u003e\u003cpre class=\"language-matlab\"\u003e'10007.76'     should return 'Ten thousand and seven point seven six'\r\n'001102.34'    should return 'One thousand one hundred and two point three four'\r\n'.4'           should return 'Zero point four'\r\n'4.'           should return 'Four'\r\n'0.' and '.'   should return 'Zero'\r\n'340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine'\r\n\u003c/pre\u003e\u003cp\u003eIn the British short scale notation:\u003c/p\u003e\u003cpre class=\"language-matlab\"\u003e1 Hundred      = 10^2\r\n1 Thousand     = 10^3\r\n1 Million      = 10^6\r\n1 Billion      = 10^9\r\n1 Trillion     = 10^12\r\n1 Quadrillion  = 10^15\r\n1 Quintillion  = 10^18\r\n1 Sextillion   = 10^21\r\n1 Septillion   = 10^24\r\n1 Octillion    = 10^27\r\n1 Nonillion    = 10^30\r\n1 Decillion    = 10^33\r\n1 Vigintillion = 10^63\r\n1 Centillion   = 10^303\r\n\u003c/pre\u003e","function_template":"function out_str = n2t(in_str)\r\n  out_str = in_str;\r\nend","test_suite":"%%\r\nx = '0';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0.003';\r\ny_correct = 'Zero point zero zero three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0.';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '.343';\r\ny_correct = 'Zero point three four three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n%%\r\nx = '.';\r\ny_correct = 'Zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx='23000000011.2330';\r\ny_correct = 'Twenty three billion and eleven point two three three zero';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '1,700,343.04014';\r\ny_correct = 'One million seven hundred thousand three hundred and forty three point zero four zero one four';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '4,003,900,030,001';\r\ny_correct = 'Four trillion three billion nine hundred million thirty thousand and one';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '50506';\r\ny_correct = 'Fifty thousand five hundred and six';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '5001000';\r\ny_correct = 'Five million one thousand';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '101000';\r\ny_correct = 'One hundred and one thousand';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '100003.0000341';\r\ny_correct = 'One hundred thousand and three point zero zero zero zero three four one';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '3.14159265358979';\r\ny_correct = 'Three point one four one five nine two six five three five eight nine seven nine';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '0497, 367, 158, 401, 387, 490, 191, 320, 142.72931574943292322499550584316';\r\ny_correct = 'Four hundred and ninety seven septillion three hundred and sixty seven sextillion one hundred and fifty eight quintillion four hundred and one quadrillion three hundred and eighty seven trillion four hundred and ninety billion one hundred and ninety one million three hundred and twenty thousand one hundred and forty two point seven two nine three one five seven four nine four three two nine two three two two four nine nine five five zero five eight four three one six';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '10000000000000000000000000600000000000000000000000000000000000000';\r\ny_correct = 'Ten vigintillion six hundred thousand decillion';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n%%\r\nx = '2878366142600744685534686064407323355445697471111330511689595534';\r\ny_correct = 'Two vigintillion eight hundred and seventy eight octillion three hundred and sixty six septillion one hundred and forty two sextillion six hundred quintillion seven hundred and forty four quadrillion six hundred and eighty five trillion five hundred and thirty four billion six hundred and eighty six million sixty four thousand four hundred and seven decillion three hundred and twenty three nonillion three hundred and fifty five octillion four hundred and forty five septillion six hundred and ninety seven sextillion four hundred and seventy one quintillion one hundred and eleven quadrillion three hundred and thirty trillion five hundred and eleven billion six hundred and eighty nine million five hundred and ninety five thousand five hundred and thirty four';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nx = '34000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001.580023';\r\ny_correct = 'Thirty four centillion and one point five eight zero zero two three';\r\nassert(isequal(n2t(x),y_correct), [x '  ' n2t(x)])\r\n\r\n%%\r\nfiletext = fileread('n2t.m');\r\nassert(isempty(strfind(filetext, 'regexp')));\r\nassert(isempty(strfind(filetext, 'assert')));\r\nassert(isempty(strfind(filetext, 'eval'))) \r\nassert(isempty(strfind(filetext, '!'))) \r\nassert(isempty(strfind(filetext, 'eighty seven trillion four'))) \r\nassert(isempty(strfind(filetext, 'three point zero four zero one four'))) \r\nassert(~isempty(strfind(filetext, 'three'))) \r\nassert(~isempty(strfind(filetext, 'n2t'))) \r\nassert(isempty(dir ('assert.m')))\r\nassert(isempty(dir ('fileread.m')))\r\nassert(isempty(dir ('isempty.m')))\r\n","published":true,"deleted":false,"likes_count":1,"comments_count":1,"created_by":310490,"edited_by":null,"edited_at":null,"deleted_by":null,"deleted_at":null,"solvers_count":4,"test_suite_updated_at":null,"rescore_all_solutions":false,"group_id":1,"created_at":"2019-08-20T13:01:17.000Z","updated_at":"2019-08-22T07:17:53.000Z","published_at":"2019-08-22T07:17:53.000Z","restored_at":null,"restored_by":null,"spam":false,"simulink":false,"admin_reviewed":false,"description_opc":"{\"relationships\":[{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/document\",\"targetMode\":\"\",\"relationshipId\":\"rId1\",\"target\":\"/matlab/document.xml\"},{\"relationshipType\":\"http://schemas.mathworks.com/matlab/code/2013/relationships/output\",\"targetMode\":\"\",\"relationshipId\":\"rId2\",\"target\":\"/matlab/output.xml\"}],\"parts\":[{\"partUri\":\"/matlab/document.xml\",\"relationship\":[],\"contentType\":\"application/vnd.mathworks.matlab.code.document+xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?\u003e\\n\u003cw:document xmlns:w=\\\"http://schemas.openxmlformats.org/wordprocessingml/2006/main\\\"\u003e\u003cw:body\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eUsing the British short scale notation, write a function to return the correct spelling of a number passed as a numeric string including decimal places. The function should be able to accept spaces, commas and leading zeros. Numbers beginning with '.' should return 'Zero point something' and numbers ending in '.' should state only the integer part.\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eExamples:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA['10007.76'     should return 'Ten thousand and seven point seven six'\\n'001102.34'    should return 'One thousand one hundred and two point three four'\\n'.4'           should return 'Zero point four'\\n'4.'           should return 'Four'\\n'0.' and '.'   should return 'Zero'\\n'340,139'      should return 'Three hundred and forty thousand one hundred and thirty nine']]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"text\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003eIn the British short scale notation:\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003cw:p\u003e\u003cw:pPr\u003e\u003cw:pStyle w:val=\\\"code\\\"/\u003e\u003c/w:pPr\u003e\u003cw:r\u003e\u003cw:t\u003e\u003c![CDATA[1 Hundred      = 10^2\\n1 Thousand     = 10^3\\n1 Million      = 10^6\\n1 Billion      = 10^9\\n1 Trillion     = 10^12\\n1 Quadrillion  = 10^15\\n1 Quintillion  = 10^18\\n1 Sextillion   = 10^21\\n1 Septillion   = 10^24\\n1 Octillion    = 10^27\\n1 Nonillion    = 10^30\\n1 Decillion    = 10^33\\n1 Vigintillion = 10^63\\n1 Centillion   = 10^303]]\u003e\u003c/w:t\u003e\u003c/w:r\u003e\u003c/w:p\u003e\u003c/w:body\u003e\u003c/w:document\u003e\"},{\"partUri\":\"/matlab/output.xml\",\"contentType\":\"text/xml\",\"content\":\"\u003c?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"no\\\" ?\u003e\u003cembeddedOutputs\u003e\u003cmetaData\u003e\u003cevaluationState\u003emanual\u003c/evaluationState\u003e\u003clayoutState\u003ecode\u003c/layoutState\u003e\u003coutputStatus\u003eready\u003c/outputStatus\u003e\u003c/metaData\u003e\u003coutputArray type=\\\"array\\\"/\u003e\u003cregionArray type=\\\"array\\\"/\u003e\u003c/embeddedOutputs\u003e\"}]}"}],"term":"tag:\"large numbers\"","current_player_id":null,"fields":[{"name":"page","type":"integer","callback":null,"default":1,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"per_page","type":"integer","callback":null,"default":50,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"sort","type":"string","callback":null,"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":null,"prepend":true},{"name":"body","type":"text","callback":null,"default":"*:*","directive":null,"facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":false},{"name":"group","type":"string","callback":null,"default":null,"directive":"group","facet":true,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"difficulty_rating_bin","type":"string","callback":null,"default":null,"directive":"difficulty_rating_bin","facet":true,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"id","type":"integer","callback":null,"default":null,"directive":"id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"tag","type":"string","callback":null,"default":null,"directive":"tag","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"product","type":"string","callback":null,"default":null,"directive":"product","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"created_at","type":"timeframe","callback":{},"default":null,"directive":"created_at","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"profile_id","type":"integer","callback":null,"default":null,"directive":"author_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"created_by","type":"string","callback":null,"default":null,"directive":"author","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"player_id","type":"integer","callback":null,"default":null,"directive":"solver_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"player","type":"string","callback":null,"default":null,"directive":"solver","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"solvers_count","type":"integer","callback":null,"default":null,"directive":"solvers_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"comments_count","type":"integer","callback":null,"default":null,"directive":"comments_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"likes_count","type":"integer","callback":null,"default":null,"directive":"likes_count","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"leader_id","type":"integer","callback":null,"default":null,"directive":"leader_id","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true},{"name":"leading_solution","type":"integer","callback":null,"default":null,"directive":"leading_solution","facet":null,"facet_method":"and","operator":null,"param":"term","static":null,"prepend":true}],"filters":[{"name":"asset_type","type":"string","callback":null,"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":null,"static":"\"cody:problem\"","prepend":true},{"name":"profile_id","type":"integer","callback":{},"default":null,"directive":null,"facet":null,"facet_method":"and","operator":null,"param":"author_id","static":null,"prepend":true}],"query":{"params":{"per_page":50,"term":"tag:\"large numbers\"","current_player":null,"sort":"map(difficulty_value,0,0,999) asc"},"parser":"MathWorks::Search::Solr::QueryParser","directives":{"term":{"directives":{"tag":[["tag:\"large numbers\"","","\"","large numbers","\""]]}}},"facets":{"#\u003cMathWorks::Search::Field:0x00007fbf330b6f40\u003e":null,"#\u003cMathWorks::Search::Field:0x00007fbf330b6ea0\u003e":null},"filters":{"#\u003cMathWorks::Search::Field:0x00007fbf330b64a0\u003e":"\"cody:problem\""},"fields":{"#\u003cMathWorks::Search::Field:0x00007fbf330b71c0\u003e":1,"#\u003cMathWorks::Search::Field:0x00007fbf330b7120\u003e":50,"#\u003cMathWorks::Search::Field:0x00007fbf330b7080\u003e":"map(difficulty_value,0,0,999) asc","#\u003cMathWorks::Search::Field:0x00007fbf330b6fe0\u003e":"tag:\"large numbers\""},"user_query":{"#\u003cMathWorks::Search::Field:0x00007fbf330b6fe0\u003e":"tag:\"large numbers\""},"queried_facets":{}},"query_backend":{"connection":{"configuration":{"index_url":"http://index-op-v2/solr/","query_url":"http://search-op-v2/solr/","direct_access_index_urls":["http://index-op-v2/solr/"],"direct_access_query_urls":["http://search-op-v2/solr/"],"timeout":10,"vhost":"search","exchange":"search.topic","heartbeat":30,"pre_index_mode":false,"host":"rabbitmq-eks","port":5672,"username":"cody-search","password":"78X075ddcV44","virtual_host":"search","indexer":"amqp","http_logging":"true","core":"cody"},"query_connection":{"uri":"http://search-op-v2/solr/cody/","proxy":null,"connection":{"parallel_manager":null,"headers":{"User-Agent":"Faraday v1.0.1"},"params":{},"options":{"params_encoder":"Faraday::FlatParamsEncoder","proxy":null,"bind":null,"timeout":null,"open_timeout":null,"read_timeout":null,"write_timeout":null,"boundary":null,"oauth":null,"context":null,"on_data":null},"ssl":{"verify":true,"ca_file":null,"ca_path":null,"verify_mode":null,"cert_store":null,"client_cert":null,"client_key":null,"certificate":null,"private_key":null,"verify_depth":null,"version":null,"min_version":null,"max_version":null},"default_parallel_manager":null,"builder":{"adapter":{"name":"Faraday::Adapter::NetHttp","args":[],"block":null},"handlers":[{"name":"Faraday::Response::RaiseError","args":[],"block":null}],"app":{"app":{"ssl_cert_store":{"verify_callback":null,"error":null,"error_string":null,"chain":null,"time":null},"app":{},"connection_options":{},"config_block":null}}},"url_prefix":"http://search-op-v2/solr/cody/","manual_proxy":false,"proxy":null},"update_format":"RSolr::JSON::Generator","update_path":"update","options":{"url":"http://search-op-v2/solr/cody"}}},"query":{"params":{"per_page":50,"term":"tag:\"large numbers\"","current_player":null,"sort":"map(difficulty_value,0,0,999) asc"},"parser":"MathWorks::Search::Solr::QueryParser","directives":{"term":{"directives":{"tag":[["tag:\"large numbers\"","","\"","large numbers","\""]]}}},"facets":{"#\u003cMathWorks::Search::Field:0x00007fbf330b6f40\u003e":null,"#\u003cMathWorks::Search::Field:0x00007fbf330b6ea0\u003e":null},"filters":{"#\u003cMathWorks::Search::Field:0x00007fbf330b64a0\u003e":"\"cody:problem\""},"fields":{"#\u003cMathWorks::Search::Field:0x00007fbf330b71c0\u003e":1,"#\u003cMathWorks::Search::Field:0x00007fbf330b7120\u003e":50,"#\u003cMathWorks::Search::Field:0x00007fbf330b7080\u003e":"map(difficulty_value,0,0,999) asc","#\u003cMathWorks::Search::Field:0x00007fbf330b6fe0\u003e":"tag:\"large numbers\""},"user_query":{"#\u003cMathWorks::Search::Field:0x00007fbf330b6fe0\u003e":"tag:\"large numbers\""},"queried_facets":{}},"options":{"fields":["id","difficulty_rating"]},"join":" "},"results":[{"id":553,"difficulty_rating":"easy-medium"},{"id":61147,"difficulty_rating":"medium"},{"id":54355,"difficulty_rating":"medium"},{"id":54280,"difficulty_rating":"medium-hard"},{"id":44955,"difficulty_rating":"hard"}]}}