Advertisement
Guest User

Untitled

a guest
Jun 19th, 2018
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.19 KB | None | 0 0
  1. /*********************************************************************\
  2.       |        _            ____     _          _           ____      |
  3.      / \      | \     |    /    \   | \     |  | \     |   /    \     |
  4.     /   \     |  \    |   /      \  |  \    |  |  \    |  /      \    |
  5.    /-----\    |   \   |  |        | |   \   |  |   \   | |        |   |
  6.   /       \   |    \  |   \      /  |    \  |  |    \  |  \      /    |
  7.  /         \  |     \_|    \____/   |     \_|  |     \_|   \____/     |
  8.                                                                       |
  9.                                                                       |
  10.     codeforces: safayet007 || codechef: saf1ano2_1234                 |
  11.     BUET EEE '17                                                      |
  12.                                                                       |
  13. **********************************************************************/
  14.  
  15.  
  16. #include <stdio.h>
  17.  
  18. int strrlen(char *str)
  19. {
  20.     int length = 0, i;
  21.     for(i = 0; *(str + i); i++)
  22.     {
  23.         length++;
  24.     }
  25.     return length;
  26. }
  27.  
  28. int main() {
  29.     char text[500];
  30.     gets(text);
  31.     printf("%d\n", strlen(text));
  32.     return 0;
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement