Skip to content
Snippets Groups Projects
Select Git revision
  • 2023ws
  • 2024ws default
  • 2022ws
  • 2021ws
  • 2020ws
  • 2018ws
  • 2019ws
  • 2017ws
  • 2016ws
9 results

strings-07.c

Blame
  • strings-07.c 335 B
    #include <stdio.h>
    #include <string.h>
    
    int main (void)
    {
      char hello[] = "Hello, world!\n";
    
      printf ("%s\n", hello);
      printf ("%zd\n", strlen (hello));
    
      printf ("%s\n", hello + 7);
      printf ("%zd\n", strlen (hello + 7));
    
      return 0;
    
      hello[5] = 0;
      printf ("%s\n", hello);
      printf ("%zd\n", strlen (hello));
    
      return 0;
    }