abhishah501's blog

By abhishah501, history, 7 years ago, In English

Given a string determine whether it is a ‘sum-string’. A string is called a sum-string if it satisfies the following properties: len(s)>3 sub-string(i,x) + sub-string(x+1,j) = sub-string(j,l) example: “12358” is a sum string. Explanation : 1+2 = 3 ; 2+3 = 5 ; 3+5 = 8 “199100199” is a sum string. Explanation: 1+99 = 100 ; 99+100 = 199 “2368” is not a sum string.

Can anyone help me solve this question.

  • Vote: I like it
  • -18
  • Vote: I do not like it