ExamVeda
Login
Home
51
What is the output of this program?
#!/bin/bash
echo "Which file do you want to check"
read x
until [ -e $x ]
do 
echo "The file does not exist. Do you want to create? y/n"
read a
if [ $a = y ]; then  
touch $x
echo "Your file has been created successfully."
fi
done
echo "The file is present in this directory"
exit 0
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
52
In this program the allocated memory block can store
#include<stdio.h>
#include<stdlib.h>
 
int main()
{
    int *ptr;
    ptr = malloc(10);
    return 0;
}
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
53
Indicate the right option to search for BOB, Bob, BOb or BoB?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
54
What is the output of this program?
#include<stdio.h>
#include<fcntl.h>
#include<sys/stat.h>
#include<semaphore.h>
 
int main()
{
    sem_t* sem_id;
    sem_id = sem_open("sem_value",O_CREAT,0666,0);
    if(sem_id == SEM_FAILED)
        perror("sem_open");
    if(sem_close(sem_id) == -1)
        perror("sem_close");
    sem_wait(sem_id);
    printf("Example\n");
    return 0;
}
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
55
If a and b are 2 variables then the meaning of a<<=b is
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
56
Which is Fastest IPC?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
57
What is the output of this program?
#include<stdio.h>
 
int main()
{
    fork();
    printf("Example\n");
    return 0;
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
58
What UNIX command is used to update the modification time of a file?
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
59
The print and printf statements can be told to send their output to other place except standard output, is called
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
60
Which file is used primarily for diagnosing memory fragmentation issues ?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board