I have to use syslog to log a message on terminal.
I found a code on internet but it is not working.
code: 

```
 #include <stdio.h>
 #include <unistd.h>
 #include <syslog.h>

int main(void) 
{    
openlog("slog", LOG_PID|LOG_CONS, LOG_USER);  
syslog(LOG_INFO, "A different kind of Hello world ... ");
closelog();  
 return 0;
}

```