ast_comparator/test/student_data/handout/shlab-handout/cases/63_tsh.c
/*
 * builtin_cmd - If the user has typed a built-in command then execute
 *    it immediately.
 */
If the user has typed a built-in command then execute
it immediately.
If the user has typed a built - in command then execute it immediately .
int builtin_cmd(char **argv)
{
  if(!strcmp(argv[0],"quit")) exit(0);
  if(!strcmp(argv[0],"jobs")) {
		listjobs(jobs);
  	return 1;
  }
  if(!strcmp(argv[0],"bg") || !strcmp(argv[0],"fg")){
  	do_bgfg(argv);
  	return 1;
  }
  return 0;    
}
int builtin_cmd ( char * * argv ) { if ( ! strcmp ( argv [ 0 ] , " " ) ) exit ( 0 ) ; if ( ! strcmp ( argv [ 0 ] , " " ) ) { listjobs ( jobs ) ; return 1 ; } if ( ! strcmp ( argv [ 0 ] , " " ) || ! strcmp ( argv [ 0 ] , " " ) ) { do_bgfg ( argv ) ; return 1 ; } return 0 ; }
builtin_cmd - If the user has typed a built-in command then execute
    it immediately.
builtin_cmd - If the user has typed a built - in command then execute it immediately .
/*int i;
  	for (i = 0; i < MAXJOBS; i++) {
    if (jobs[i].pid != 0 && (jobs[i].state == BG || jobs[i].state == ST)){
    	char *status = jobs[i].state == ST ? "Stopped" : "Running";
      printf("[%d] (%d) %s %s", jobs[i].jid, jobs[i].pid, status, jobs[i].cmdline);
  		}
		}*/