Wednesday 26 November 2014

bca1020 smu bca fall 2014 Ist sem assignment

Get fully solved assignment, plz drop a mail with your sub code
computeroperator4@gmail.com
Charges for mba rs 125/subject and rs 700/semester only.
For other rs 125/subject only
if urgent then call us on 08791490301, 08273413412
our website is www.smuassignment.in
PROGRAM: BCA (REVISED FALL 2012)

SEMESTER: FIRST

SUBJECT CODE & NAME: BCA1020- PROGRAMMING IN C

CREDIT: 4

BK ID: B1639

MAX. MARKS: 60
Q.1: Define operators. Briefly explain about any four Operators in C.
ANS:
C supports a rich set of operators. An operator is a symbol that tells the computer to perform certain mathematical or logical manipulations. Operators are used in programs to manipulate data and variables. They usually form a part of the mathematical or logical expressions.
Arithmetic Operators
The basic operators for

Q2. Differentiate between while and do-while statements [5+5] 10
Answer.
1. In while loop the condition is tested first and then the statements are executed if the condition turns out to
be true.
In do while the statements are executed for the first time and then the conditions are tested, if the condition turns out to be true then the statements are
executed again.


Q.3: Describe about static and external variables.
ANS:
Static Variables
Static variables are defined within individual functions and therefore have the same scope as automatic variables, i.e. they are local to the functions in which they are declared. Unlike automatic variables, however,

Q4. Define structure. What is the syntax for defining a structure? Write a simple program using structure.
Answer:
Definition:

A Structure definition creates a format that may be used to declare structure variables. For e.g., Consider a book database consisting of book name, author, number of pages and price.

struct book_bank
{
char title[20];
char

Q.5: Define macro. How we can declare a macro statement? Explain with an example.

ANS:

A preprocessor line of the form
#define name text
Defines a macro with the given name, having as its value the given replacement text. After that (for the rest of the current source file), wherever the preprocessor sees that name, it will replace it with the replacement text.


Q.6:What is the use of fopen () and fclose () function? List and explain different modes for opening a file.

ANS:

fopen():
To open the file input.dat for reading you might call
ifp = fopen ("input.dat", "r");
The mode string "r" indicates reading. Mode "w" indicates writing, so we could open output.dat for output like this:
Get fully solved assignment, plz drop a mail with your sub code
computeroperator4@gmail.com
Charges for mba rs 125/subject and rs 700/semester only.
For other rs 125/subject only
if urgent then call us on 08791490301, 08273413412
our website is www.smuassignment.in



No comments:

Post a Comment