Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download

High Performance Computing Assignment

Project: HPC
Views: 171
1
#include <stdlib.h>
2
#include <stdio.h>
3
#include <lsCommand.h>
4
#include <pwdCommand.h>
5
6
int main(int argc, char **argv)
7
{
8
char *input;
9
char args;
10
int i;
11
/*char **args;
12
int status;*/
13
14
printf("Assignment 1 Command Line \n");
15
printf("$ ");
16
scanf("%s", input);
17
18
while(input != "exit")
19
{
20
do
21
{
22
//printf("Assignment 1 Command Line \n");
23
//printf("$ ");
24
if(input == "ls")
25
{
26
lsCommand();
27
}
28
else if(input == "pwd")
29
{
30
pwdCommand();
31
}
32
else
33
{
34
exit(0);
35
}
36
37
}
38
39
while(i);
40
}
41
}
42