small error of repitation of char:
String ascii difference
@souravkhan654,
There is repetition because for e.g, for i=1, you will print a[0],x,a[1], and then for i=2, you will print a[1],x,a[2]. See a[1] got repeated.
i tried if else condition but i got same ascii difference
@souravkhan654,
Don’t just try by hit and trial to solve the problem, come up with an algorithm, dry run it on paper, and then implement. Currently, you are implementing, and you don’t even have a algorithm, leave alone dry run.
1 Like