About Me

My photo
Vijayapur, Karnataka, India
I am interested in Teaching.

Tuesday 26 December 2017

Module wise important questions on "Unix and Shell Programming" for VTU examination

Module wise most expected questions on 
"Unix and Shell Programming"

    Module-1
    1. Explain in brief about "UNIX Architecture" with neat diagram.
    2. List and explain 3 working UNIX environment.
    3. Explain the following UNIX commands with minimum 2 examples.
        1. echo  2. calc  3. man  4. who  5. clear
    4. What are internal and external commands? list and explain with examples.
    5. Write short note on super user.
    6. What are file attributes? Explain two ways to change the file permissions with example.


    Module-2
    1. What is file in UNIX? Discuss the types of files supported by Unix.
    2. Explain: absolute and relative path names.
    3. Explain Directory handling commands supported by Unix. (pwd, mkdir, cd, rmdir)
    4. Explain File handling commands (cat, rm, cp, mv, wc, od_
    5. What is ls command? Explain with all options and examples.
    6. Explain Directory permissions.


    Module-3
    1. Explain 3 modes of vi editor with a neat diagram.
    2. Explain Navigation commands used while working with vi editor.
    3. Discuss the following commands.
        set, amp and abbr commands.
    4. Discuss the the Shell's Interpretive Cycle.
    5. What are grep and egrep commands? Explain with examples.
    5. Explain the following commands.
         pipe and tee
    6. Explain the Three Standard Files used for Redirection.
     7. Discuss pattern matching with wild-cards
    Module-4
    1. What is shell script? Write a shell script to read pattern and file name to search from given input file using grep command.
    2. Explain the conditional statements supported by UNIX with syntax and examples.
    3. Explain case statement supported by UNIX with general format and example.
    4. Explain the while and until loop statements supported by UNIX with syntax and examples.
    5. Explain sort utility supported by UNIX with options & examples.
    6. What are file links? explain hard and soft links.
    7. Explain Escaping and Quoting with examples.
    8. Practice Shell Programs from Sumitabha Das authour text book.


    Module-5
    1. What is process in UNIX? Explain parent-child processes with example.
    2. Discuss ps command with different options supported by UNIX.
    3. What are cron and crontab files? Discuss.
    4. What are nice and nohup commands? Discuss.
    5. Explain bg and fg commands.
    6. What is PERL programming? Discuss its importance.
    7. Explain structure of Perl Script.
    8. Discuss string handling functions supported by Perl Scripts.
    9. Explain default variables $. & $_
    10. Explain list and arrays supported by Perl.
    11. Discuss splice and join commands.


    Dear student,
      Good luck for the forthcoming Annual Examination.
      To score good marks, you need to follow the following tips.
    1. You need to write correct answer for the asked question instead of writing unnecessary things for example for the question What is your name? You need to write the following answers.
    My name is John, or My full name is John K. Henry or Introduce more about you.But, do not write like My name is ____ (name is missing)
    2. First, you need to increase quality, then quantity of quality.
    3. Minimum one page answer for any of the question.
    4. If, question carry 5 marks then minimum 2 pages with 2 examples.
    5. If, question carry 10 marks, then minimum front/back 4 pages with examples.
    6. Wherever necessary, draw figure with figure and labels.

    First explain the topic.....Then write Syntax......Then write Examples.....List OPTIONS if any in Table with explanation.....Give few examples for few options......

    7. Write minimum 3 examples for each UNIX command. If you do not write examples, then you loose marks.
    8. Practice Shell and Perl programs from the text book of Sumitabha Das author.
    9. Yes, you are intelligent, go ahead, reach your goal, "your future is bright do not spoil it" said by V.T.U.
    10. Whatever you write, write neatly with correct question number.
    11. Do no compare yourselves with others! instead compare yourself with your last performance!.
    12. Move the examination hall with Hall Ticket, ID card, Blank ink ball pen and compass box.
    13. Write your V.T.U. no. correctly on answer booklet.
    14. Yours sign and supervisor sign is must on answer booklet.


    In your free time, kindly fill the Feedback Form......


    Good Luck!

    Yours Teacher

    Mr. C. S. Kusur
    Asst. Prof. Dept. of CSE
    BLDEA's V. P. Dr. P. G. H. College of Engineering and Technology, Vijayapur.
    cs.kusur@gmail.com
     9739762682

    Monday 18 December 2017

    Model Question Paper "PCD" Odd Sem. 2017-18

    Module 1

    1. What is pseudocode? Give any two examples.

    2. What are c tokens? list and explain in brief.

    3. Write 'structure of c program' with programming example.

    4. What is variable? Discuss its declaration and initialization with syntax and examples.

    5. Write rules for defining identifiers(variables) with example for each rule.

    6. What are datatypes? list and explain in brief.

    7. What are formatted I/O functions? List and explain with syntax and examples.

    8. Discuss the following c operators with examples.
        relational, logical, conditional, increment/decrement

    9. What is type conversion(typecast)? Discuss different types with examples.

    10. Write an algorithm and draw a flowchart to find largest of 3 numbers.

    11. Write c programs for following
          To find simple interest
          To find area and perimeter of rectangle
          To swap the contents of two variables using temporary variable.
          To swap the contents of two variables without using temporary variable.

    Module-2

    1. What are conditional (decision making/branching) statements? discuss the following with syntax and examples.
    simple if, if else, nested if, else if ladder

    2. Discuss 'switch' statement with syntax , flowchart and programming example.

    3. Discuss the following with syntax and examples.

    while

    do while

    for

    4. Write differences between break and continue statements.

    5. Write c programs for following
        To find largest of three numbers.
        To check year for leap year.
        To check, whether the number is PALINDROME or not.
        To find factorial of N.
       
    Module-3

    1. What is 1D array? Discuss its declaration and initialization with syntax and examples.

    2. What is 2D array? Discuss its declaration and initialization with syntax and examples.

    3. What is string? Discuss its declaration and initialization with syntax and examples.

    4. Discuss the following with syntax and examples.

    strlen    strcpy   strncpy   strcmp    strncmp    strcat    strncat    strrev   strlwr    strupr

    5. Discuss elements of user defined functions

    6. What are actual and formal parameters? Discuss with examples.

    7. Discuss the parameter passing mechanisms. Call by value and call by reference

    8. What is recursive function? give programming example.

    9. Discuss storage classes used in C.

    10. Write C programs for following
        To find length of a string
        Function to check, whether the number is prime or not prime
        Function to swap the two variables using call by reference

    Module-4

    1. What is structure? Discuss its declaration and initialization with syntax and examples.

    2. Discuss arrays of structure with syntax and examples.

    3. What is typedef statement? Give examples.

    4. How to define, open and closing a file discuss with syntax with examples.

    5. Discuss file handling I/O functions with syntax and examples.

    Module-5
    1. What is data structure? List different types.

    2. What is stack? Discuss its operations with figures and write its applications.

    3. What is queue? Discuss its operations with figures and write its applications.

    4. What is linked list? Discuss with examples.

    5. What are preprocessors? Discuss the types of pre processors with examples.


    Wish you all the best!

    Your answers must be neat and correct.

    Send your feedback to cs.kusur@gmail.com or send the feedback form.













    Wednesday 6 December 2017

    Tuesday 28 November 2017

    Computer Programming Lab: Viva-Voce Questions on C programming language

    Dear students,

    You are hereby informed to follow the following instructions to get good marks in Practical Examinations.

    Wear the formal and decent dresses on the practical examination day!

    Do prayer and move towards exams.

    Be calm and healthier on that day.

    Day before the exam, do not eat spicy food.

    Move to laboratory with HALL TICKET and JOURNAL (Observation notebook)

    Be polite with all the staff members in laboratory.

    Be positive and be confident.

    First, fill all the academic details on answer sheet correctly.

    First, complete the write up work and show to examiners.

    Then, start the machine.

    Give appropriate file name with dot C extension.

    Do not forget to save the file after every modification, Press F2 in between

    Remember the filename.

    Remove the errors by your own and save the file.

    Check the  CHITS near by your bench and if found, inform the staff members.

    You should not have any other chits or mobile phone with you.

    Once, you execute the C program, call examiners and show the output for different set of inputs.

    Then, write outputs in your answer booklet.

    You will be called for Viva-Voce at any time, be ready...

    Most commonly asked Viva Voce Questions are as follows.

    What is computer program?

    What is the difference between variable and constant.

    What are data types?

    Can you name operators supported by C?

    What is compiler?

    Why do we compile the program?

    What are I/O functions?

    Name formatted I/O functions.

    Name input functions available in C.

    Name output functions available in C.

    Why? do we include stdio.h include our C program.

    Name decision making (conditional) statements available in C.

    Can you tell me the differences between simple if, if else, nested if, else if ladder and switch.

    Name loop statements available in C.

    Can you tell me the differences while, do while and for loop statements.

    What is the difference between break, continue and goto statements?

    What is an array?

    What is an structure?

    What is a string?

    Can you tell me the drawback of arrays?

    Can you tell me the difference between arrays and structures?

    Name string handling functions and their use.

    What is user defined function? Can you tell me advantages.

    Name parameter passing mechanisms.

    Difference between call by value and call by reference

    What is pointer?

    Advantages of pointers.

    What is FILE?

    Name file handling functions.

    What is data structure?

    Name types of data structure.

    What is stack?

    Can you tell me the operations to be perform on stack.

    Can you tell me the applications of stack.

    What is queue?

    What is linked list?

    What are pre processors? Give examples.



    Good luck and all the best.......

    Yours....

    Chidanand S. Kusur
    Asst. Prof.
    Dept. of CSE
    BLDEA's V. P. Dr. P. G. H. College of Engineering and Technology,
    Vijayapur.
    cs.kusur@gmail.com, cs.kusur@bldeacet.ac.in
    9739762682

    Note: send your feedback to cs.kusur@gmail.com that encourages me to help you more.



























    Tuesday 14 November 2017

    Third Assignment of USP (Open Book Test on 15th Nov 2017)

    What is shell script? Explain the following statements with syntax and examples. (10 marks)
        i) if     ii) case    iii) while  iv) for


    What is shell programming? Write a shell program to create a menu and execute a given options based on users choice. Options include.
    i)List of users  ii) List of processes  iii) List of files  iv) Current date   v)Content of files   vi) Display current login users (10 marks)

    Explain the following with an example.  (8 marks)
        i) head    ii) tail   iii) cut   iv) paste


    Explain with example set and shift commands in Unix to manipulate positional parameters. (08 marks)


    Explain sort command with options and examples. (6 marks)


    Distinguish between hard link and soft link with neat diagram and examples. (06 marks)


    What is process? Explain the mechanisms of process creation. (06 marks)


    Explain the following commands. (6 marks)
    i) at  ii)batch  iii) cron  & crontab




    Friday 13 October 2017

    USP Assignment-II (part-2): Happy Deepawali!

    1. What is shell script? Explain in detail with example.

    2. Write shell scripts for following.
    To display "Hello World" message
    To display today's date with appropriate message.
    To read pattern to be search and file name to display the records from given file.
    To perform arithmetical operations like addition, subtraction, multiplication, division and modulus operations by reading two values.

    3. Write short note "command line arguments" used in Unix.
     

    || Happy Deepawali ||

    PCD Assignment-2 (Part-II) on Functions

    1. Discuss the three elements of user defined functions with syntax and example.

    2. Explain actual and formal parameters with programming example.

    3. Discuss the following with programming examples.
        1. Call by value
        2. Call by address (reference)

    4. What is recursive function? write recursive function to find factorial of 'n'.

    5. Discuss the storage classes used in C with examples.
       (automatic, global, static, register)

    6. Write user defined function to swap the contents of two variables. (call by address)

    7. What is structure? Discuss its declaration and initialization with syntax examples.

    8. Write C program to read and display students information(roll no, name, total, avg) by using structure variable.

    9. Write a c program to read and display 'n' students information(roll no, name, total, avg) using structure and arrays.



    || Happy Deepawali ||

    Saturday 23 September 2017

    PCD Assignment 2 for II sem 'K' division students

    1. Discuss the following loop statements with syntax and programming examples.
         while, do while and for

    2. Discuss the following loop interrupt statements with syntax and programming examples.
        break and continue

    3. Discuss goto unconditional statement with syntax and example.

    4. Write differences between while and do while loop statements.

    5. Write differences between break and continue statements.

    6. What is one dimensional array? Discuss its declaration and initialization with syntax and examples.

    7. What is two dimensional array? Discuss its declaration and initialization with syntax and examples.

    8. What is string? Explain its declaration and initialize with examples.

    9. Explain all string handling functions with examples.

    Write c programs for following.

    To find factorial of 'n' using while loop.
    To find factorial of 'n' using do while loop.
    To find factorial of 'n' using for loop.
    To find largest and lowest of n numbers.
    To check, whether the number 'n' is prime number or not prime number.
    To sort 'n' numbers in ascending order by using bubble sort technique.
    To implement linear search technique.
    To implement binary search technique.
    To find addition of two matrices.
    To find multiplication of two matrices.












    Friday 22 September 2017

    USP Assignment-2 for III Sem. 'B' CSE students

    1. What are file permissions? Discuss the two ways of changing files permissions with examples.

    2. Explain chmod command with syntax and examples.

    3. What are directory permissions? Discuss with examples.

    4. Write the default file permissions in UNIX and explain.

    5. Write the default directory permissions in UNIX and explain.

    6. Write the Unix commands to set the following file permissions by using both Relative and Absolute methods for the following files.
           -rw_rwxr_x             file1
          -_w_rwx_wx            file2

    7. Write the Unix commands to set the following file permissions by using both Relative and Absolute methods for the following directories.
           drw_rw_r_ _          CSE
           dr_xrwx rw _          ISE

    8. Discuss the three modes of vi editor with neat diagram.

    9. Discuss Navigation Commands used in vi editor with examples.

    10. Discuss the commands used for "Editing Text in vi editor".

    11. Discuss about "searching and replacing patterns in vi editor"

    12.  How to configure the vi environment. Discuss the commands. (set,ab,map)

    13. Write short note on ".exrc" file.

    ................................................................................................................................................

    1. Discuss the steps involved in "Shell's Interpretive Cycle".

    2. List and explain with examples about "wild card characters" used with filenames in Unix.

    3. Discuss "removing special meaning of wild cards" with examples.
        (Escaping and Quoting)

    4. What is redirection in Unix? Discuss three types of redirection with neat diagram and examples.
        (three standard files)








     


    Wednesday 13 September 2017

    Portion for First I.A. USP

    Module-1    All bits....

    Module-2   Types of Unix files, 

                        Parent Child Relationship, 

                        Working with directories (commands), 

                        Working with files (commands) 



    Saturday 26 August 2017

    Assignment 1: Programming in C and Data Structures

    Dear student,
      You are hereby informed to answer the following questions by reading recommended books and given notes. Write the answers in your own technical sentences. You answers must contain some additional points rather than given points in my notes. (Read--Understand--Re write)

    1. Define algorithm. Give one examples.(3m)
    Definition=1 m, Explanation=1m Two Examples=1m

    2. Define flowchart. Give one example.(3m)
    Definition=1 m, Explanation=1m Two Examples=1m

    3. Write algorithm and draw flowchart to find simple interest.(2+2=4m)

    4. Write algorithm and draw flowchart to find area and circumference of a circle.(2+2=4m)

    5. What is pseudocode? Give any three examples. (5m)
    Definition=1 m, Explanation=1m Three Examples=3m

    6. Discuss "Structure of C Program" with programming example.(10m)
    Definition=1m Structure=2m Explanation of all elements=5X1=5m Programming exmaple=2m

    7. What are C-tokens? List and explain in brief.(8m)
    Definition=1m List=1m Explanation=6 x 1=6m

    8. What are datatypes? List and discuss in brief with range of values supported by them.(8m)

    Definition=1m List=1m Explanation with range of values =1x5
    9. Write c program to find largest of two numbers using conditional operator (?:) (5m)

    10. Write c program to find largest of three numbers using conditional operator (?:) (5m)

    11. Write c program to find roots of a quadratic equation. (10 m)

    12. Write c program to check, whether the year is leap year or not leap year. (5m)

    13. Write c program to check whether the number N is PALINDROME or not.

    14. Write c program to swap two values using temporary variable.(3m)

    15. Write c program to swap two values without using temporary variable.(3m)

    16. Solve questions from Question Papers. (10m)

    17. What are formatted I/O functions? Explain with syntax and examples.
    Definition=1m
    Definition of scanf()=1m Syntax=1m Examples=1m
    Definition of printf()=1m Syntax=1m Examples=1m

    18. What is precedence and associativity of operator? Give example. (5m)
    Definition=1+1 2m
    Examples=2m

    19. Discuss the following operators with examples. (15m)
    Arithmetic, Relational, Logical, Assignment, Increment/decrement, bitwise and special operators.

    20. What is type conversion?Discuss different types with examples.









    Tuesday 22 August 2017

    Assignment 1 on Unix and Shell Programming (Updated)

    Dear student,

    Read recommended text books and given notes to understand and re-write the answers for following questions in assignment booklet in your own technical sentences to get good marks.


    1. Discuss 'UNIX" operating system. (4m)
        Definition=1m  Discussion=3m

    2.  List and explain the features of Unix o.s. (8m)
        List=1m Explanation= (7x1 =7m)
     
    3. Discuss 'Unix Architecture' with neat diagram. (8m)
        Diagram with labeling =2m
        Explanation of Kernel, System calls, Shell, Utilities, Applications and Users carry (6x1)

    4. Discuss the three Computing Environments of Unix with free hand sketch. (7m)
        List of environments=1m Free hand sketch=2m Explanation=3x1=3m

    5. Discuss POSIX and Single Unix Specification. (6m)
        POSIX explanation=3m
        SUS explanation=3m

    6. List and explain in brief about 'types of Unix commands'. (3m)

    7. What is ls command? Discuss with options and examples.(6m)

    Definition of ls command :1m
    Minimum 5 options explanation with examples= 5m


    8. Discuss the following Unix commands with examples in brief.
       echo, printf, cal, date, man, more, bc, ps, wc,tput clear,  who, whoami, passwd, exit,
    Definition=1m Minimum 3 examples for each, If options are their, you need to explain.


    9. Discuss 'system variable PATH' with example.

    10. Explain the following commands with examples in brief.
          bc, man, more, tput clear, ps, wc

    11. Who is superuser and discuss the functions of superuser.

    12.  Discuss memory managements functions like df and du (imp)

    13. Discuss "User Management" by system admin. (groupdadd, useradd, usermod and userdel) (imp)

    14. Discuss "/etc/passwd and /etc/shadow" files. (imp)


    Note: Submit the assignments before 30th August 2017.




    Monday 17 July 2017

    Tips to get good marks in Viva Voce of CPL Lab

    1. Be well dressed
    2. Be polite
    3. Be cool
    4. Use these: Excuse me sir, Thank you sir, Good day sir.
    5. DO NOT CARRY ANY CHITS OR MOBILES (VERY IMP)
    6. CHECK CHITS NEAR BY YOUR COMPUTER TABLES.
    7. Remember the file name like P1.C, P2.C, etc.
    8. Do not forget to save the file frequently or after every modification i.e by pressing F2.
    9. Do not forget to save before RUN the program.
    10. Avoid the Change of Question procedure. If you change the Question, then you have to execute the new program compulsory.




    Frequently asked questions.
    1. What is variable?
    2. What are constants?
    3. Difference between variable and constant.
    4. Name decision making statements.
    5. Name loop statements.
    6. What is an array?
    7. What is structure?
    8. Difference between array and structure.
    9. What is pointer?
    10. Difference between while and do while loop.
    11. Difference between break and continue.
    12. Name dynamic memory allocation functions.
    13. Name pre-processors.
    14. What is stack?
    15. Applications of stack
    16. What is queue?
    17. Applications of queue
    18. Name Input functions available in C.
    19. Name Output functions available in C.
    20. Difference between scanf and fscanf
    21. Difference between printf and fprintf
    22. Difference between call by value and call by reference.
    23. Difference between automatic, global, static and register variables.
    24. Name data types available in C.
    25. What is the difference between PRIMARY and SECONDARY memory.
    26. What is FILE?
    27. Name file handling functions.

    Computer Basics
    1. What is computer?
    2. Name input and output devices.
    3. What is the unit of computer's memory?
    4. Types of computer's memory.
    5. What RAM and ROM stands for?
    6. Examples for secondary memories.
    7. Difference between computer program and software.

    Good luck ! All the best! Be positive...






    Sunday 18 June 2017

    PCD Module Wise Important Questions for Annual Examination

    Module-I
    1. What is pseudocode? Write pseudocode to find simple interest.

    2. Discuss "Structure of C Program" with programming example.

    3. What are C-tokens? List and explain in brief.

    4. What is variable? Write rules for defining variables with valid and invalid example for each rule.
    or
     What are identifiers? Write rules for defining identifiers with valid and invalid example for each rule.

    5. What are datatypes? List and explain in brief with range of values supported by them.
    6. Explain the following C-operators with examples.

        Relational, Logical, Bitwise, Special operators(sizeof(), comma) and conditional operator(?:).

    7. What is meant by precedence and asociativity of operators? Explain with example.

    8. Solve the following C- Expression.
        10<9+5&&500*10, 4||5&&3&&!7

    9. What is type conversion(typecast)? List and explain types of type conversions with example.

    10. Convert the following Mathematical expressions into C-expressions.
       


    11. Write C programs for following.

    To find simple interest.
    To find area and perimeter of triangle  by reading breadth and height of it.
    To find area and perimeter of triangle  by reading 3 sides of it.
    To find area and perimeter of rectangle.
    To convert the temperature reading from Fahrenheit to Celsius.
    To swap two values using temporary variable.
    To swap two values without using temporary variable.

    Module-2
    1. What are decision making (branching or conditional) statements ? Discuss any three with SYNTAX, FLOWCHART and PROGRAMMING example.
    or
     Discuss the following with syntax,flow chart and programming example.
                        a) simple...if  b)if..else  c)nested if  d) else..if ladder (cascaded if )

    2. Discuss "switch" statement with SYNTAX, FLOWCHART and programming example.

    3. What are loop (repetitive or loop) statements ? Discuss any three with SYNTAX, FLOWCHART and PROGRAMMING example.
    or
     Discuss the following with syntax,flow chart and programming example.
                        a) the while loop    b) the do...while loop    c) the for loop.

    4. Write minimum 5 differences between while(pretest or entry controlled)  and do...while (post test or exit controlled) loop.

    5. Write minimum 5 differences between break and continue statements.

    6. What is goto (unconditional) statement? discuss with example.

    7. Write the C programs for following.

    To check, whether the year is leap or not leap year.
    To find largest of two numbers.
    To find largest of three numbers.
    To reverse a number.
    To check, whether the number is PALINDROME or NOT PALINDROME
    To find factorial of n
    To find gcd and lcm of two numbers.

    Module-3

    1. What is one dimensional array? Explain its declaration and initialization with syntax and example.

    2. What is two dimensional array? Explain its declaration and initialization with syntax and example.

    3. What is string? Explain its declaration and initialization with syntax and example.

    4. Discuss the following string manipulating functions with examples.
        strlen, strcpy, strncpy, strcmp, strncmp, strcat. strncat, strlwr, strupr, strrev

    5. Write the C programs for following.

    To find addition of two one dimensional arrays.
    To implement Bubble Sort technique.
    To implement Linear Search technique.
    To implement Binary Search technique.
    To find addition of two 2D arrays
    To find multiplication of two 2D arrays
    To find length of a string without using built in function.

    Functions:
    1. Discuss the "Elements of User Defined Functions" with syntax and examples.

    2. What are actual and formal parameters? Give programming example.

    3. What is recursive function? Write recursive function to find factorial of 'n'.

    4. Discuss 'parameter passing mechanisms' with programming example to each. (call by value and call by reference)
    or
    Write differences between 'call by value' and call by reference' (call by address)

    5. Write C program to swap two values using defined function to swap two values.(call by reference) vimp.

    6. Discuss the following with example.
    automatic variables, global variable, static variables and register variables.

    7.  Write C program that calls isprime(n) as a user defined function that returns 1 if the number is prime;otherwise, 0.

    Module-4

    Structure:

    1. What is structure?Explain its declaration and initialization with syntax and examples.

    2. Write differences between arrays and structures.

    3. What is nested structure? Give programming example.

    4. Discuss 'arrays of structure' with programming example.

    5. Discuss 'structure and functions' with example.

    6. What is typedef statement? Give examples.

    7. Write C program to read and display 'n' students information (Roll No, Name, Marks, Grade) using arrays of structure.

    File Management:

    1. What is file? Discuss defining, opening and closing a file with syntax and example.

    2. Discuss the following "File Manipulation Functions" with syntax and examples.
        getc() and putc()
        getw() and putw()
        fscanf() and fprintf()
        gets() and puts()

    Module-5

    1. What is pointer? Discuss its declaration and initialization with syntax and examples.

    2. What is dynamic memory allocation? Explain the following functions with example.
         malloc(), calloc(), realloc(), free()

    3. List and explain non-primitive data structures. (stack,queue,linked list, tree and graph)

    4. What are preprocessors? list and explain 3 types.
       a) Macro substitution b) File inclusion c) Compiler control

    5. Discuss 'stack' with explanation, figure and applications.

    6. Discuss 'queue' with explanation, figure and applications.

    7. Discuss 'linked list' with explanation and  figure.






    Dear student,
    Remember one thing i.e. if you write more then you get good and more marks.So, you need to explain the topics with quality points and SYNTAX  and PROGRAMMING EXAMPLE compulsory.

    Tips:
    1. Preferably, attempt that question first in which you are perfect.
    2. For every question minimum one page answer.
    3. For 10 Marks, minimum 3 pages. (front,back,front)
    4. Wherever necessary, give the programming examples as you memorized for lab.
    5. Write MORE to get MORE marks.
    6. Your answers must be neat and tidy.
    7. Do not forget to underline or bold the important words in your answer.
    8. Draw rectangle box around SYNTAX compulsory.
    9. Send you feedback or suggestion to cs.kusur@gmail.com
    10. All the best...










    Tuesday 16 May 2017

    PCD Assignment-IV for III I.A.

    1. Write a c program to read and display 'n' students information(roll no, name and marks) using    
        arrays of structure.

    2. Discuss 'nested structure' with example.

    3. What is 'typedef statement'?Give examples.

    4. What is file? Discuss defining, opening and closing a file with syntax and example.

    5. Discuss the following "File Manipulation Functions" with syntax and examples.
        getc() and putc()
        getw() and putw()
        fscanf() and fprintf()
        gets() and puts()

    6. What is pointer? Discuss its declaration and initialization with syntax and examples.

    7. What is dynamic memory allocation? Explain the following functions with example.
         malloc(), calloc(), realloc(), free()

    8. List and explain non-primitive data structures. (stack,queue,linked list, tree and graph)

    9. What are preprocessors? list and explain 3 types.





    Tuesday 2 May 2017

    One must know the answers for these questions of PCD

    Know the following:

    What are loop statements? 
    What is while loop?
    What is do-while loop?
    What is for loop?
    What is break statement?
    What is continue statement?
    What is goto statement?
    What is an array?
    What is 1D array?
    What is 2D array?
    What is string?
    What is user defined function?
    What are the differences between call by value and call by reference methods?
    What is recursive function?
    What is structure?
    How to define structure and structure variables?
    What are the differences between structure and array?
    String handling functions.


    Important programs for the practice:
    To check, whether the number is Palindrome or not palindrome.
    To find factorial of 'n' number.
    To find sum and average of 1 to n numbers.
    To check, whether the number 'n' is prime or not prime.
    To find length of string without using built-in function.
    To read and display Students Information(roll no, name, marks) using structure variable.



    Write user defined function to find factorial of 'n' i.e. fact(n)
    Write recursive function to find factorial of 'n' i.e. fact(n)
    Write user defined function to find factorial of 'n' i.e. isprime(n)
    C program to swap contents of two variables using user defined function using call by reference method.




    Sunday 23 April 2017

    DAA Assignment -3

    1. Discuss "Greedy Technique" with general plan and coin change problem as an example.

    2. What is minimum spanning tree (MST)? Discuss.

    3. List the algorithms used to find MST.

    4. Discuss the following algorithms with "Algorithm" and example.
        Prim's Algorithm
        Kruskal's Algorithm.

    5. Discuss "Dijkstra Algorithm" with algorithm and example.

    6. Discuss "Huffman Codes and Huffman Trees" with example.

    7. Discuss "Heaps and Heap Sort" algorithms with examples.

    8. Discuss "Job Sequencing with deadlines" with example.

    NOTE: Submit the assignments at the earliest......

    Assignments on Functions (Assignment -IV)

    1. What is function? Write its advantages with one programming example.

    2. What is the difference between built-in and user defined function?

    3. Discuss the "Elements of User Defined Functions" with explanation, syntax and examples.

    4. Write user defined functions for following.
       
        To find sum of two integers.   i.e. sum(n1,n2)
        To find area of circle.              i.e. ac(r)
        To find factorial of 'n'              i.e. fact(n)
        To find largest of two numbers i.e. large(n1,n2)
        To find largest of three numbers i.e. max(n1,n2,n3)
        To find square and cube of a number. (Write two functions square(n) and cube(n) and call in main())
         To check, whether the number is prime or not prime i.e. by creating your own functions as isprime(n) that reurns 1 if the number is prime;otherwise, 0.

    5. List and discuss categories of functions with programming examples.
       functions with arguments and return values.
       functions with no arguments and return values.
       functions with arguments and no return values.
       functions with no arguments and no return values.

    6. What are actual and formal parameters? Discuss with example.

    7. What is recursive function? Give programming example. i.e. Write recursive function to find factorial of 'n'. (vimp)

    8. Discuss "Parameter Passing Mechanisms" with programming examples. (call by value and call by reference)) (vvimp)

    9. Write difference between "call by value" and "call by reference" methods.

    10. Write user defined function to swap the contents of two variables using call by reference(address) method. (vvimp)

    11. Discuss storage classes used in C. i.e. auto, global, static and register variables. (vimp)









    Tuesday 18 April 2017

    PCD Assignment-IV

    1. What is one dimensional array? Explain its declaration and initialization with syntax and examples.
         (2+2+2=6 m)

    2. What is two dimensional array? Explain its declaration and initialization with syntax and examples.
         (2+2+2=6 m)

    3. List the advantages and disadvantages of working with arrays. (3+3=6m)
     
    4. What is string? Explain its declaration and initialization with syntax and examples.
      (2+2+2=6 m)

    5. Discuss the following "String Handling Functions" with syntax and examples (programming examples).
        strlen(), strcpy(), strncpy(), strcmp(), strncmp(), strcat(), strncat(), strupr(), strlwr(), strrev().
        Note: Explanation :1m, Syntax 1m, 2 simple examples and 1 programming example carry 3m.
        Each function carry= 5 m.

    6. List the advantages and disadvantages of both linear and binary search techniques.

    7. Solve questions from "Old VTU Question Papers" on "Arrays" and "Strings" topic.

    8. Write the C programs for following.

    C program to find 'sum' and average' of 'n' elements using 1D array.
    C program to find largest and lowest of 'n' numbers using 1D array.
    C program to sort 'n' elements using Bubble Sort technique.
    C program to implement linear search technique.
    C program to implement binary search technique.
    C program to find the addition of two 2D arrays.
    C program to find the product/multiplication of two 2D arrays.


    NOTE:
    Read, Understand and re-write the answers for the questions in assignment book in your own sentences.
    Submit the assignment at the earliest.












     



    Saturday 1 April 2017

    First I. A. Toppers in PCD

    Congratulations !
    First Topper: Miss. Oswal
    Second Toppers: Miss Neha & Miss Lakkamma

    Friday 31 March 2017

    PCD Assignment-III

    1. What are loop statements? List different types of loop statements supported by C language.

    2. Discuss "while" loop with syntax, flowchart and two programming examples.

    3. Write C programs for following using "while" loop.
         To display 1 to n natural numbers.
         To display Squares of 1 to n numbers.
         To display multiple table of 'n' in multiple table format.
         if n=2,
                 2 x 1 = 2
                2 x 2 = 4
                 ....
               2 x 10 = 20

         To find sum and average of 1 to n numbers.
         To find factorial of n number.
         To check, whether the entered number is Palindrome or Not Palindrome.
         To find GCD of two numbers using Euclid's algorithm.

    4. Discuss "do ... while" loop with syntax, flowchart and two programming examples.


    5. Discuss "for" loop with syntax, flowchart and two programming examples.

    6. Write the differences between break and continue statements.

    7. What is goto statement? Discuss with programming example.

    8. Write C programs for the following
        To check, whether the number is PALINDROME or NOT PALINDROME.
        To check, whther the number 'n' is PRIME or NOT PRIME.
        To display first 'n' fibonacci numbers.






    Friday 24 March 2017

    DAA Assignment-II

    1. What is an algorithm? Explain the notion of algorithm with an example.
    2. Explain in brief about ‘Algorithm design and analysis process’ with a neat flowchart.
    3. Explain ‘Asymptotic Notations’ with definition and examples.
    4. Discuss the ‘Algorithm Analysis Framework’ in brief.
    5. Discuss basic efficiency classes.
    6. Discuss the algorithms specifications.
    7. Discuss General Plan for Analyzing Time Efficiency of Recursive Algorithms.
    8. Discuss General Plan for Analyzing Time Efficiency of Nonrecursive Algorithms.
    9. Write an algorithm to check whether all the elements in a given array are distinct and find its time complexity.
    10. Write an algorithm to find the product of two matrices A and B and find its time complexity.
    11. Write recursive algorithm to compute factorial of n and find its time complexity.
    12. Discuss and find the time complexity of “Tower of Hanoi” puzzle.
    13. Discuss divide-and-conquer algorithm design technique with example.
    14. Write recursive algorithm to find maximum and minimum of given list of array elements using divide and conquer technique.
    15. Write recursive and non-recursive algorithms for binary search.
    16. Write Merge Sort algorithm to find its worst case time efficiency.
    17. Write Quick Sort algorithm to find its best case time efficiency.
    18. Apply Quick Sort on the given list and draw recursive call tree:  5  3 1  9  8 2 4  7

    Sunday 19 March 2017

    PCD Assignment-III

    1. What are formatted I/O functions? Explain with syntax and examples.

    2. What are unformatted I/O functions? Explain with syntax and examples.

    3. Explain the following operators in brief with examples.
    Arithmetic, Relational, Logical, Increment / Decrement  operators and Bitwise operators.

    4. What is conditional operator? Explain with syntax and example.

    5. What are special operators? list and explain.

    6. What is precedence and associativity of operator? Explain with example.

    7. Solve the following mathematical expressions using precedence and associativity rules.

        a)  8&&7+100/5==1%10-5<10+(10/2)
        b) 5 && 10<<5+10

    8. What is type conversion? List and explain different types with examples.

    9. Convert the any ten mathematical expressions(as discussed in class) into C expressions.

    10. What are decision making statements? Explain the following with syntax and programming examples.
    simple if, if ... else statement and nested if statement.

    11. What is cascaded if statement? Explain with syntax and example.

    12. Discuss "switch" statement with syntax, flowchart and programming example.

    13. Write C programs for following

    1). To check for leap year.

    2). To find largest of three numbers.

    3). To check, whether the machine is 16 bits machine or not.

    4). If the user entered name is your's name and password is your roll number, then permit the user to find area and perimeter of rectangle.

    5). To display the Grades like "Honour" (Avg>=70), "First Division" (Avg>=60 and Avg<70), "Second Division" (Avg>=50 and Avg<60), "Passed" (Avg>=35 and Avg<50), "Fail" (Avg<35) by using else if ladder statement.

    6). To provide menu options to find "Area of Circle", "Area of Rectangle" and "Area of Triangle" to work accordingly using switch statement.

    7). To simulate "Simple Calculator" using switch statement.

    8) To find roots of a quadratic equation for three non-zero coefficients a, b and c. (Lab Program)

    9) SOLVE QUESTION PAPERS.



     
       








    Friday 3 March 2017

    Achievers of the week

    1. Seminar on "String Processing" by Mr. Mahesh Gajakosh (2BL15CS045)

    2. Seminar on "Graph Problems" by Miss. Nafisa Mujawar (2BL16CS407)



        
    1. Mr. Manjunath Angadi IV Sem CSE A div.
        Design and Analysis of Algorithms:




    2. Mr. Muragesh M II  Sem E Div. 2BL16CV049
        Programming in C and Data Structures

    Tuesday 28 February 2017

    Design and Analysis of Algorithms: Assignment-II

    1. Discuss the importance of "Asymptotic Notations" used by computer professionals.

    Explanation of each notation: 1m
    Definition of each notation: 2m
    Figure showing the order of growth: 2m
    Minimum 2 examples: 1m
    Total=6 marks x 3 Notations=18 Marks.


    2. Write short note on "little-oh notation" (1+1+1=3m)

    3. Write the 'General Plan to find time efficiencies' for non-recursive algorithms with example. (5m)

    4. Write pesudocode and find the time efficiency of following algorithms. (5 x 10m=50 marks)
        
        To find largest element in a list of n numbers.

         Pseudocode=3m
         Five Steps to find Time Efficiency= 5m
         Total=10m.

        Element Uniqueness Problem.
        Product of 2 matrices A and B. (Matrix Multiplication)
        To find the number of binary digits in a binary representation of decimal number.

    5. Prove the following  THEOREM (5m)

        If t1(n) = O(g1(n)) and t2(n) = O(g2(n)) then
            t1(n)+t2(n) = O(max{g1(n),g2(n))



        




    Sunday 26 February 2017

    PCD Assignment-II

    1. Explain in brief about 'STRUCTURE OF C PROGRAM' with programming example. (1+2+2+2=7m)
    Distribution of marks:
    What is structure of C program= 1m,
    Structure=2m,
    Explanation of all parts=2m,
    Programming Example=2m, Total=7 marks.
    Write this answer twice, if you are not confident; otherwise, once in assignment book.

    2. What are C-tokens? List and explain in brief with examples. (1+1+6=8 marks)
    Distribution of marks:
    What are C-tokens= 1m,
    List=1m,
    Explanation of all=6 X 1 m=6m
    Total=8 marks.
    Write this answer twice, if you are not confident; otherwise, once in assignment book.

    3. Write the rules for defining identifiers/variables with valid and invalid examples for each rule. (2.5+2.5=5 marks)
    Distribution of marks:
    Minimum 5 rules = 2.55m,
    Valid and Invalid Examples for each rule=2.5m
    Total=5 marks.
    Write this answer twice, if you are not confident; otherwise, once in assignment book.

    4. What is variable? How do you define(declare) and initialize? Explain with syntax and examples.
    (2+3+3=8 marks)
    Distribution of marks:
    Definition of variable = 2 m
    Declaration of variables= Syntax+Explanation+Examples=3m
     Initialization of variables= Syntax+Explanation+Examples=3m
    Total=8 marks.
    Write this answer twice, if you are not confident; otherwise, once in assignment book.

    5. Design and Develop C programs for following. (5 x 5=25 marks)

    C program to find largest of two numbers using simple if statement.
    C program to find largest of three numbers using simple if statement.
    C program to find largest of two numbers using  if else statement.
    C program to find largest of three numbers using if else statement.
    C program to check, whether the year is leap year or not leap year.

    Sunday 19 February 2017

    P C D Notes Page 1 of Module 1

    Introduction to Computers and Programming
    What is a computer?
    Computer is an electronic computing device. It receives raw data as in input, process and generates desired as an output. If necessary, the input and output can be stored within computer’s secondary memory for future use.
    Functions of a computer: The major four function of a computer system are as follows.
    1. Input (reads raw data as input from user’s of machine)
    2. Process (processes the input by using set of programs)
    3. Output (result will be generated and displayed/printed)
    4. Store (stores input & output within secondary memory)
    What is computer program?
    The set of instructions/statements/commands given to a machine by the programmer to do specific task is called computer program.
    Who is programmer?
    The person, who writes computer programs using(learning) computer programming languages like ALGOL, B, BCPL, C, C++, Fortran, COBOL, HTML, C#,Python, and Perl,etc.
    Types of Computer Languages:
    1. Machine level language (low level)
    Machines knows, only 0s and 1s (binary digits i.e. bits) . It is difficult for the programmer to give instructions in machine level language to solve problem. Hence, researchers developed assembly and high level languages.
    2. Assembly level language
    The researchers developed assembly level languages to make computer programming easier. In this type, programmers will use mnemonics or abbreviations like ADD, SUB, MUL, DIV, STO, PRT, R1, R2, MOV, etc to give instruction to a machine.
    e.g. MASAM (Microsoft’s Assembler)
    Assembler: The translator or system program that converts the program written in assembly language in to machine language.
    3. High level language
    The researchers developed high level language to make computer programming easier. In this type, programmer makes the use of English words and mathematical operators and expression to write computer programs to do specific task. This language is easier to learn and write computer programs. Examples. ALGOL, B, BCPL, C, ANSI C, ISO C, C99, C++, Java, Python,etc.
    Compiler: The translator or system program that converts the program written in high level language in to machine language at once.

    Interpreter: The translator or system program that converts the program written in high level language in to machine language line by line (statement by statement).


    Write a c program to display the “Hello World!” message on screen.
    /* a c program to display the “Hello World!” message */
    # include<stdio.h>
    void main()
    {
    clrscr();
    printf(“Hello World!”);
    getch();
    }

    Write a c program to find addition of 2 unknown whole numbers.
    /* a c program to find addition of two numbers */
    # include<stdio.h>
    void main()
    {
    int n1,n2,ans;
    clrscr();
    printf(“Enter any two numbers ”);
    scanf(“%d%d”,&n1,&n2);
    ans=n1+n2;
    printf(“\n Addition is %d ”,ans);
    getch();
    }

    Assignments: Write C programs for the following by your own.
    1. To find addition of three unknown whole numbers.
    2. To find addition of three unknown real numbers.
    3. To find area and circumference of a circle.
    4. To convert temperature reading from Fahrenheit to Celsius.
    5. To find simple interest.
    6. To find area and perimeter of a rectangle.
    7. To find area of triangle by reading breadth and height of it.
    8. To find area of triangle by reading 3 sides of it.
    9. To swap (interchange) the contents of two variables (computer’s memories) using temporary variable.
    10. To swap (interchange) the contents of two variables (computer’s memories) without using temporary variable.
    11. To find square and cube of a number.

    12. To extract and display last digit of entered number.