Questions

Q:

Write a c program to create dos command type.

Answer

#include
int main( int count,char * argv[] ) {
    int i;
    FILE *ptr;
    char *str;
    char ch;
    if( count == 1) {


         printf( "The syntax of the command is incorrect.\n" );
    }
    for( i=1;i<cout;i++ ){
         ptr=fopen(argv[i],"r");
         if(ptr==NULL){
             printf("The system cannot find the file specified.");
             if(count>2)
                 printf("\nError occurred while procesing : %s.\n",argv[i]);
         }
         else {
             if(count>2) {
                 printf("%s\n\n",argv[i]);
             }
             while((ch=getc(ptr))!=-1)
                 printf("%c",ch);
         }
         fclose(ptr);
    }
    return 0;
}


 


Save the above file as open.c, compile and execute the go to command mode (current working directory) and write: open xy.c (xy.c any file present in that directory)
To run the open command in all directories and drive you will have to give the path of current working directory in command mode. Write:
C:tc\bin>PATH c:\tc\bin
Now press enter key. Now your open command will work in all directory and drive.

Report Error

View answer Workspace Report Error Discuss

Subject: Programming

0 2878
Q:

Most highly intelligent mammals are

A) Elephants B) Kangaroos
C) Whales D) Dolphins
 
Answer & Explanation Answer: D) Dolphins

Explanation:

Dolphins are the most highly intelligent mammals.

Report Error

View Answer Report Error Discuss

Filed Under: Animals and Birds
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

9 2877
Q:

World’s longest 3D printed concrete bridge opened in?

A) China B) Japan
C) Dubai D) India
 
Answer & Explanation Answer: A) China

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Longest, Shortest, Deepest
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

3 2876
Q:

What is a primary benefit of location targeting?

Answer

The ability to target combinations of countries, territories, and regions.

Report Error

View answer Workspace Report Error Discuss

2 2876
Q:

Who of the following is not a recepient of 2011 Nobel Peace prize

A) Hu Jintao B) Leymah Gbowee
C) Ellen Johnson Sirleaf D) Tawakkol Karman
 
Answer & Explanation Answer: A) Hu Jintao

Explanation:
Report Error

View Answer Report Error Discuss

Filed Under: Honours and Awards

0 2876
Q:

In the below puzzle, a word starts and ends with the same letter. Can you figure out what the word is?

_otato_

Answer

rotator

Report Error

View answer Workspace Report Error Discuss

Subject: Word Puzzles

18 2876
Q:

Choose what replaces '?' in the following figure ?

creative111486456294.jpg image

A) Q B) O
C) M D) N
 
Answer & Explanation Answer: D) N

Explanation:

The alphabetical value of the letters in the left hand column follows through the sequence of Prime Numbers, with the letters in the right hand column representing the corresponding reverse alphabetical values. So,

M = Reverse of M = N.

Report Error

View Answer Report Error Discuss

Filed Under: Missing letters puzzles
Exam Prep: AIEEE , Bank Exams , CAT , GATE , GRE , TOEFL
Job Role: Bank Clerk , Bank PO

6 2876
Q:

The atmosphere is unaffected by changes in the geosphere.

A) TRUE B) FALSE
Answer & Explanation Answer: A) TRUE

Explanation:

True, the given statement that the atmosphere is unaffected by changes in the geosphere.

Report Error

View Answer Workspace Report Error Discuss

Subject: General Science
Exam Prep: AIEEE , Bank Exams , CAT
Job Role: Analyst , Bank Clerk , Bank PO

1 2876