Tnou Study Center

Blog Owner: Vignesh A





Search This Blog

Showing posts with label BCA first year Assignment Question and Answer. Show all posts
Showing posts with label BCA first year Assignment Question and Answer. Show all posts

Sunday, December 9, 2012

BCA 01 (Computer Fundamentals and Pc Software) TNOU first year Assignment 2012 batch



BCA 01 (Computer Fundamentals and Pc Software)
Answer all the Question (3 x5 =15) (Each answer will be 150 Words)
1.      Explain the futures of Multiprogramming Operating System
Answer:
The multiprogramming operating system.

The multiprogramming operating system can execute several jobs concurrently by switching the attention of the CPU back and forth among them. This switching is usually prompted by a relative slow input, output storage request that can be handled by a buffer, spooler or channel freeing the CPU to continue processing .
Multiprogramming makes efficient use of the CPU by overlapping the demands for the CPU and its I/O devices from various users. It attempts to increase CPU utilization by always having something for the CPU to execute.

The primary reason multiprogramming operating system was developed and the reason they are popular, is that they enable the CPU to be utilized more efficiently. If the operating system can quickly switch the CPU to another task whenever the being worked in requires relatively slow input, output or storage operations, then CPU is not allowed to stand idle.

Future of multiprogramming operating system:
i) It increases CPU utilization.
ii) It decreases total read time needed to execute a job.
iii) It maximizes the total job throughput of a computer.
Example: three jobs are submitted
Almost no contention for resources
All 3 can run in minimum time in a multitasking environment (assuming JOB2/3 have enough CPU time to keep their I/O operations active)
____________________________________________________________________________________
2.      (i)   WHAT IS GUI ?
A graphical user interface (GUI) is a human-computer interface (i.e., a way for humans to interact with computers) that uses windows, icons and menus and which can be manipulated by a mouse (and often to a limited extent by a keyboard as well).
GUIs stand in sharp contrast to command line interfaces (CLIs), which use only text and are accessed solely by a keyboard. The most familiar example of a CLI to many people is MS-DOS. Another example is Linux when it is used in console mode (i.e., the entire screen shows text only).
A window is a (usually) rectangular portion of the monitor screen that can display its contents (EXAMPLE: a program, icons, a text file or an image) seemingly independently of the rest of the display screen. A major feature is the ability for multiple windows to be open simultaneously. Each window can display a different application, or each can display different files (e.g., text, image or spreadsheet files) that have been opened or created with a single application.
An icon is a small picture or symbol in a GUI that represents a program (or command), a file, a directory or a device (such as a hard disk or floppy). Icons are used both on the desktop and within application programs. Examples include small rectangles (to represent files), file folders (to represent directories), a trash can (to indicate a place to dispose of unwanted files and directories) and buttons on web browsers (for navigating to previous pages, for reloading the current page, etc.).
Commands are issued in the GUI by using a mouse, trackball or touchpad to first move a pointer on the screen to, or on top of, the icon, menu item or window of interest in order to select that object. Then, for example, icons and windows can be moved by dragging (moving the mouse with the held down) and objects or programs can be opened by clicking on their icons.
2.(II) Explain the Classification of Viruses
Answer:
Computer Viruses are classified according to their nature of infection and behavior. Different types of computer virus classification are given below.
• Boot Sector Virus: A Boot Sector Virus infects the first sector of the hard drive, where the Master Boot Record (MBR) is stored. The Master Boot Record (MBR) stores the disk's primary partition table and to store bootstrapping instructions which are executed after the computer's BIOS passes execution to machine code. If a computer is infected with Boot Sector Virus, when the computer is turned on, the virus launches immediately and is loaded into memory, enabling it to control the computer.
• File Deleting Viruses: A File Deleting Virus is designed to delete critical files which are the part of Operating System or data files.
• Mass Mailer Viruses: Mass Mailer Viruses search e-mail programs like MS outlook for e-mail addresses which are stored in the address book and replicate by e-mailing themselves to the addresses stored in the address book of the e-mail program.
• Macro viruses: Macro viruses are written by using the Macro programming languages like VBA, which is a feature of MS office package. A macro is a way to automate and simplify a task that you perform repeatedly in MS office suit (MS Excel, MS word etc). These macros are usually stored as part of the document or spreadsheet and can travel to other systems when these files are transferred to another computers.
• Polymorphic Viruses: Polymorphic Viruses have the capability to change their appearance and change their code every time they infect a different system. This helps the Polymorphic Viruses to hide from anti-virus software.
• Armored Viruses: Armored Viruses are type of viruses that are designed and written to make itself difficult to detect or analyze. An Armored Virus may also have the ability to protect itself from antivirus programs, making it more difficult to disinfect.
• Stealth viruses: Stealth viruses have the capability to hide from operating system or anti-virus software by making changes to file sizes or directory structure. Stealth viruses are anti-heuristic nature which helps them to hide from heuristic detection.
• Polymorphic Viruses: Polymorphic viruses change their form in order to avoid detection and disinfection by anti-virus applications. After the work, these types of viruses try to hide from the anti-virus application by encrypting parts of the virus itself. This is known as mutation.
• Retrovirus: Retrovirus is another type virus which tries to attack and disable the anti-virus application running on the computer. A retrovirus can be considered anti-antivirus. Some Retroviruses attack the anti-virus application and stop it from running or some other destroys the virus definition database.
• Multiple Characteristic viruses: Multiple Characteristic viruses has different characteristics of viruses and have different capabilities.

3.      I) write Short notes on Mail Merge ?
Answer:
A mail merge is a method of taking data from a database, spreadsheet, or other form of structured data, and inserting it into documents such as letters, mailing labels, and name tags. It usually requires two files, one storing the variable data to be inserted, and the other containing both the instructions for formatting the variable data and the information that will be identical across each result of the mail merge.
For example, in a form letter, you might include instructions to insert the name of each recipient in a certain place; the mail merge would combine this letter with a list of recipients to produce one letter for each person in the list.
You can also print a set of mailing labels or envelopes by doing a mail merge. For labels, for example, you would construct a source document containing the addresses of the people you wish to print labels for and a main document that controls where each person's name, address, city, state, and zip code will go on the label. The main document would also contain information about how many labels are on a page, the size of each label, the size of the sheet of paper the labels are attached to, and the type of printer you will use to print the labels. Running a mail merge with the two files results in a set of labels, one for each entry in the source document, with each label formatted according to the information in the main document.
Most major word processing packages (e.g., Microsoft Word) are capable of performing a mail merge.
                                                Part B
Answer the Following: (1 X10) With 300 Words
1.Explain the Network Architecture of OSI reference Model ?
The open systems interconnection (OSI) model is a product of the open systems interconnection effort at the international organization for standardisation.

OSI - An architectural model for open networking systems that was developed by the International Organization for Standardization (ISO) in Europe in 1974. The Open Systems Interconnection (OSI) reference model was intended as a basis for developing universally accepted networking protocols, but this initiative essentially failed for the following reasons:
  • The standards process was relatively closed compared with the open standards process used by the Internet Engineering Task Force (IETF) to develop the TCP/IP protocol suite.
  • The model was overly complex. Some functions (such as connectionless communication) were neglected, while others (such as error correction and flow control) were repeated at several layers.
  • The growth of the Internet and TCP/IP—a simpler, real-world protocol model—pushed the OSI reference model out.
The OSI reference model is best seen as an idealized model of the logical connections that must occur in order for network communication to take place. Most protocol suites used in the real world, such as TCP/IP, DECnet, and Systems Network Architecture (SNA), map somewhat loosely to the OSI reference model. The OSI model is a good starting point for understanding how various protocols within a protocol suite function and interact.
The OSI reference model has seven logical layers, as shown in the following table.
It is a characterising and standardizing the functions of communications system in terms of abstraction layers.
 The following figure shows the network architecture of OSI reference model.

                  

Layer Name
Description
7
Application layer
Interfaces user applications with network functionality, controls how applications access the network, and generates error messages. Protocols at this level include HTTP, FTP, SMTP, and NFS.
6
Presentation layer
Translates data to be transmitted by applications into a format suitable for transport over the network. Redirector software, such as the Workstation service for Microsoft Windows NT, is located at this level. Network shells are also defined at this layer.
5
Session layer
Defines how connections can be established, maintained, and terminated. Also performs name resolution functions.
4
Transport layer
Sequences packets so that they can be reassembled at the destination in the proper order. Generates acknowledgments and retransmits packets. Assembles packets after they are received.
3
Network layer
Defines logical host addresses such as IP addresses, creates packet headers, and routes packets across an internetwork using routers and Layer 3 switches. Strips the headers from the packets at the receiving end.
2
Data-link layer
Specifies how data bits are grouped into frames, and specifies frame formats. Responsible for error correction, flow control, hardware addressing (such as MAC addresses), and how devices such as hubs, bridges, repeaters, and Layer 2 switches operate., the logical link control (LLC) layer and the media access control (MAC) layer.
1
Physical layer
Defines network transmission media, signaling methods, bit synchronization, architecture (such as Ethernet or Token Ring), and cabling topologies. Defines how network interface cards (NICs) interact with the media (cabling).

BCA 04 (Introduction to Computer Organization) TNOU first year Assignment 2012 batch



BCA-04                                 Introduction to Computer Organization
                                                                                PART A
Answer all Questions:-
1.       Convert the Following Binary numbers to decimal
(i)                 10101010
The number 10101010 represents:
128 + 32 + 8 + 2
So, the answer is: 170

(ii)                Convert the Following decimal numbers to binary 49.25
The number 49.25 can be expressed as:
32 + 16 + 1
So, the answer is: 110001

2.       Write Short note on Star Network. (150 words)
Answer:
Star networks are one of the most common computer network topologies. In its simplest form, a star network consists of one central switch, hub or computer, which acts as a conduit to transmit messages. This consists of a central node, to which all other nodes are connected; this central node provides a common connection point for all nodes through a hub. In Star topology every node (computer workstation or any other peripheral) is connected to central node called hub or switch. The switch is the server and the peripherals are the clients. Thus, the hub and leaf nodes, and the transmission lines between them, form a graph with the topology of a star. If the central node is passive, the originating node must be able to tolerate the reception of an echo of its own transmission, delayed by the two-way transmission time (i.e. to and from the central node) plus any delay generated in the central node. An active star network has an active central node that usually has the means to prevent echo-related problems.

3.       What is Micro Programmed Control Unit.
Answer:
Microprogrammed Control Unit:
A control unit whose binary control variables are stored in memory (control memory).
The  Microprograms were organized as a sequence of microinstructions and stored in special control memory. The algorithm for the microprogram control unit is usually specified by flowchart description. The main advantage of the microprogram control unit is the simplicity of its structure. Outputs of the controller are organized in microinstructions and they can be easily replaced.
The control unit is the circuitry that controls the flow of data through the processor, and coordinates the activities of the other units within it. In a way, it is the "brain within the brain", as it controls what happens inside the processor, which in turn controls the rest of the computer. The examples of devices that require a control unit are CPUs and graphics processing units (GPUs). The modern information age would not be possible without complex control unit designs. The control unit receives external instructions or commands which it converts into a sequence of control signals that the control unit applies to the data path to implement a sequence of register-transfer level operations.
The control unit implements the instruction set of the CPU. It performs the tasks of fetching, decoding, managing execution and then storing results. It may manage the translation of instructions (not data) to micro-instructions and manage scheduling the micro-instructions between the various execution units. On some processors the control unit may be further broken down into other units, such as a scheduling unit to handle scheduling and a retirement unit to deal with results coming from the pipeline; It is the main function of CPU.
                                                                                PART B Long answer
ANSWER THE Following:
1.       I) write short notes on Registers.
In computer architecture, a processor register is a small amount of storage available as part of a CPU or other digital processor. Such registers are (typically) addressed by mechanisms other than main memory and can be accessed more quickly. Almost all computers, load-store architecture or not, load data from a larger memory into registers where it is used for arithmetic, manipulated, or tested, by some machine instruction. Manipulated data is then often stored back in main memory, either by the same instruction or a subsequent one. Modern processors use either static or dynamic RAM as main memory, the latter often being implicitly accessed via one or more cache levels. A common property of computer programs is locality of reference: the same values are often accessed repeatedly and frequently used values held in registers improves performance. This is what makes fast registers (and caches) meaningful.
Processor registers are normally at the top of the memory hierarchy, and provide the fastest way to access data. The term normally refers only to the group of registers that are directly encoded as part of an instruction, as defined by the instruction set. However, modern high performance CPUs often have duplicates of these "architectural registers" in order to improve performance via register renaming, allowing parallel and speculative execution. Modern x86 is perhaps the most well known example of this technique.
Allocating frequently used variables to registers can be critical to a program's performance. This register allocation is either performed by a compiler, in the code generation phase, or manually, by an assembly language programmer.

ii) Explain Master – Slave Flip-Flop
Master-Slave Flip-Flops :
A master-slave flip-flop is normally constructed from two flip-flops: one is the Master flip-flop and the other is the Slave. In addition to these two flip-flops, the circuit also includes an inverter. The inverter is connected to clock pulse in such a way that the inverted CP is given to the slave flip-flop. For example, if the CP=0 for a master flip-flop, then the output of the inverter is 1, and this value is assigned to the slave flip-flop. In other words if CP=0 for a master flip-flop, then CP=1 for a slave flip-flop.
A master-slave flip flop can be constructed using any type of flip-flop which forms a combination with a clocked RS flip-flop, and with an inverter as slave circuit.
The output of the master J-K flip flop is fed to the input of the slave J-K flip flop. The output of the slave J-K flip flop is given as a feedback to the input of the master J-K flip flop. The clock pulse [Clk] is given to the master J-K flip flop and it is sent through a NOT Gate and thus inverted before passing it to the slave J-K flip flop.



An RS master-slave flip-flop consists of two RS flip-flops; one is the master flip-flop and the other a slave. The inverted CP is given to the slave flip-flop. Now when CP=0, the master flip-flop is disabled. So the external inputs R and S of the master flip-flop will not affect the circuit until CP goes to 1. The inverter output goes to 1 and it enables the slave flip-flop. The output Q=Y and Q’=Y’.
When CP=1, the master flip-flop is enabled and the slave flip-flop remains isolated from the circuit until CP goes back to 0. Now Y and Y’ depends on the external inputs R and S of the master flip-flop.
Assume that the flip-flop is in a clear state and no clock pulse is applied to the circuit. The external inputs given are S=1 and R=0. This input will not affect the state of the system until the CP=1. Now the next clock pulse applied should change the state to SET state (S=1, R=0). During the clock pulse transition from 0 to 1, the master flip-flop goes to set state and changes the output Y to 1. However this does not affect the output of the system since the slave flip-flop is isolated from the system (CP=0 for slave). So no change is observed at the output of the system.
When the CP returns to 0, the master flip-flop is disabled while the slave is enabled. So the information from the master is allowed to pass through to the slave. Since Y=1, this changes the output Q to 1.
In a master slave flip-flop it is possible to change the output of the flip-flop and the external input with same clock pulse. This is because the external input S can be changed at the same time while the pulse goes through its negative edge transition. When CP=0, change in external input S would not affect the state of the system. From this behavior of the master slave flip-flop it is quite clear that the state change in flip-flops coincide with the negative edge transition of the pulse.
Negative edge transition means an inverter is attached between the CP terminal and the input of the slave. In positive edge triggered master slave flip-flops an additional inverter is attached between the CP terminal and the input of the master. Such flip-flops are triggered with negative pulses. Negative edge of the pulse affects the master and positive edge affects the slave.


BCA-03 (Introduction to System Software) TNOU first year assignment 2012 batch



BCA-03
Introduction to System Software
Answer all Questions: - (3 x 5= 15 marks) with 150 words
1.      Write the different types of Translators?
Answer:
Types of  translator:
1.      Assembler
2.      Compiler
3.      Interpreter

1.     Assembler

An assembler translates assembly language into machine code. Assembly language consists of mnemonics for machine opcodes so assemblers perform a 1:1 translation from mnemonic to a direct instruction. For example:
LDA #4 converts to 0001001000100100
Conversely, one instruction in a high level language will translate to one or more instructions at machine level.

2.     Compiler

A Compiler is a computer program that translates code written in a high level language to a lower level language, object/machine code. The most common reason for translating source code is to create an executable program (converting from a high level language into machine language).

3.     Interpreter

An interpreter program executes other programs directly, running through program code and executing it line-by-line. As it analyses every line, an interpreter is slower than running compiled code but it can take less time to interpret program code than to compile and then run it — this is very useful when prototyping and testing code. Interpreters are written for multiple platforms, this means code written once can be run immediately on different systems without having to recompile for each. Examples of this include flash based web programs that will run on your PC, MAC, games console and Mobile phone.

2.     Write Short notes on Lexical Analysis.

Lexical Analysis:

Lexical analysis is the process of analyzing a stream of individual characters (normally arranged as lines), into a sequence of lexical tokens (tokenization. for instance of "words" and punctuation symbols that make up source code) to feed into the parser. Roughly the equivalent of splitting ordinary text written in a natural language (e.g. English) into a sequence of words and punctuation symbols. Lexical analysis is often done with tools such as lex, flex and jflex.
Strictly speaking, tokenization may be handled by the parser. The reason why we tend to bother with tokenising in practice is that it makes the parser simpler, and decouples it from the character encoding used for the source code.
For example given the input string:
integer aardvark := 2, b;

output the following tokens:

keyword integer
word aardvark
assignment operator
integer 2
comma
word b
semi_colon
 
The lexical analyzer is the first phase of compiler. Its main task is to read the input characters and produces output a sequence of tokens that the parser uses for syntax analysis. As in the figure, upon receiving a get next token command from the parser the lexical analyzer reads input characters until it can identify the next token. 
Tokenized in the following table:
Lexeme
Token type
sum
Identifier
=
Assignment operator
3
Integer literal
+
Addition operator
2
Integer literal
;
End of statement
 


3.      Write the advantages of Virtual memory ?
 
Answer:
 
Virtual memory is a memory management scheme that allows the execution of processes even without loading them into the main memory. Where there is virtual memory in use, there is no need to load the entire process into the expensive main memory.

Advantages of Virtual Memory :

         Translation:
        Program can be given consistent view of memory, even though physical memory is scrambled
        Makes multithreading reasonable (now used a lot!)
        Only the most important part of program (“Working Set”) must be in physical memory.
        Contiguous structures (like stacks) use only as much physical memory as necessary yet still grow later.
         Protection:
        Different threads (or processes) protected from each other.
        Different pages can be given special behavior
          (Read Only, Invisible to user programs, etc).
        Kernel data protected from User programs
        Very important for protection from malicious programs
=> Far more “viruses” under Microsoft Windows
         Sharing:
        Can map same physical page to multiple users
(“Shared memory”)

Part B
Answer the Following Questions:

1.      Explain the Types of Operating System ?
Answer:

An operating system (OS) is a collection of software that manages computer hardware resources and provides common services for computer programs. The operating system is a vital component of the system software in a computer system. Application programs usually require an operating system to function.
Time-sharing operating systems schedule tasks for efficient use of the system and may also include accounting for cost allocation of processor time, mass storage, printing, and other resources.
For hardware functions such as input and output and memory allocation, the operating system acts as an intermediary between programs and the computer hardware,[1][2] although the application code is usually executed directly by the hardware and will frequently make a system call to an OS function or be interrupted by it. Operating systems can be found on almost any device that contains a computer—from cellular phones and video game consoles to supercomputers and web servers.

Real-time Operating System: It is a multitasking operating system that aims at executing real-time applications. Real-time operating systems often use specialized scheduling algorithms so that they can achieve a deterministic nature of behavior. The main object of real-time operating systems is their quick and predictable response to events. They either have an event-driven or a time-sharing design. An event-driven system switches between tasks based of their priorities while time-sharing operating systems switch tasks based on clock interrupts.

Multi-user and Single-user Operating Systems: Computer operating systems of this type allow multiple users to access a computer system simultaneously. Time-sharing systems can be classified as multi-user systems as they enable a multiple user access to a computer through time sharing. Single-user operating systems, as opposed to a multi-user operating system, are usable by only one user at a time. Being able to have multiple accounts on a Windows operating system does not make it a multi-user system. Rather, only the network administrator is the real user. But for a Unix-like operating system, it is possible for two users to login at a time and this capability of the OS makes it a multi-user operating system.

Multi-tasking and Single-tasking Operating Systems: When a single program is allowed to run at a time, the system is grouped under the single-tasking system category, while in case the operating system allows for execution of multiple tasks at a time, it is classified as a multi-tasking operating system. Multi-tasking can be of two types namely, pre-emptive or co-operative. In pre-emptive multitasking, the operating system slices the CPU time and dedicates one slot to each of the programs. Unix-like operating systems such as Solaris and Linux support pre-emptive multitasking. If you are aware of the multi-threading terminology, you can consider this type of multi-tasking as similar to interleaved multi-threading. Cooperative multitasking is achieved by relying on each process to give time to the other processes in a defined manner. This kind of multi-tasking is similar to the idea of block multi-threading in which one thread runs till it is blocked by some other event. MS Windows prior to Windows 95 used to support cooperative multitasking.

Distributed Operating System: An operating system that manages a group of independent computers and makes them appear to be a single computer is known as a distributed operating system. The development of networked computers that could be linked and made to communicate with each other, gave rise to distributed computing. Distributed computations are carried out on more than one machine. When computers in a group work in cooperation, they make a distributed system.

Embedded System: The operating systems designed for being used in embedded computer systems are known as embedded operating systems. They are designed to operate on small machines like PDAs with less autonomy. They are able to operate with a limited number of resources. They are very compact and extremely efficient by design. Windows CE, FreeBSD and Minix 3 are some examples of embedded operating systems.

Mobile Operating System: Though not a functionally distinct kind of operating system, mobile OS is definitely an important mention in the list of operating system types. A mobile OS controls a mobile device and its design supports wireless communication and mobile applications. It has built-in support for mobile multimedia formats. Tablet PCs and smartphones run on mobile operating systems.

Batch Processing and Interactive Systems: Batch processing refers to execution of computer programs in 'batches' without manual intervention. In batch processing systems, programs are collected, grouped and processed on a later date. There is no prompting the user for inputs as input data are collected in advance for future processing. Input data are collected and processed in batches, hence the name batch processing. IBM's z/OS has batch processing capabilities. As against this, interactive operating requires user intervention. The process cannot be executed in the user's absence.

Online and Offline Processing: In online processing of data, the user remains in contact with the computer and processes are executed under control of the computer's central processing unit. When processes are not executed under direct control of the CPU, the processing is referred to as offline. Let's take the example of batch processing. Here, the batching or grouping of data can be done without user and CPU intervention; it can be done offline. But the actual process execution may happen under direct control of the processor, that is online.