Tag Archives: words

A two-way set-associative cache memory uses blocks of four words. The cache can accommodate a total of 2048 words from the main memory. The main memory size is 128K x 32. 5m Dec2005

What is cache memory?                                                                                5m Dec2005 A two-way set-associative cache memory uses blocks of four words. The cache can accommodate a total of 2048 words from the main memory. The main memory size is 128K x 32. What are the sizes of the following?      TAG      INDEX      Data    … Read More »

A computer has 32 registers, ALU has 64 operations. in a common bus system. Formulate a control word; specify bits in each field of the control word. 5m Dec2005

A computer has 32 registers, ALU has 64 operations. All are connected to a common bus system. Formulate a control word for the computer; specify the bits in each field of the control words. 5m Dec2005 Please note the following points: The opcode size is 7 bits. So, in general it will have 27 =… Read More »

A computer has 512 words RAM with a word size of 32 bits and a cache memory of 8 Blocks with block size of 64 bits – IGNOU MCA Assignment 2014 – 15

MASTER OF COMPUTER APPLICATIONS Course Code : MCS-012 Course Title : Computer Organisation and Assembly Language Programming Assignment Number : MCA (2)/012/Assign /2014-15 Maximum Marks : 100 Weightage : 25% A computer has 512 words RAM with a word size of 32 bits and a cache memory of 8 Blocks with block size of 64… Read More »

Write a program to count the number of characters and words in a given file. 10m Jun2007

Write a program to count the number of characters and words in a given file. 10m Jun2007  #include<stdio.h> #include<process.h> void main() { FILE *fp; int chr=0,wrd=1,str; clrscr(); if((fp=fopen(“test.txt”,”r”))== NULL) { printf(“File does not exist\n”); exit(0); } while(!(feof(fp))) { str=fgetc(fp); if(str==’ ‘) wrd++; chr++; } printf(“The number of characters in file :%d\n”,chr); printf(“The number of words… Read More »

Design an algorithm and draw corresponding flowchart to print the value of the number in words when the number entered is in the range of 1 to 299. 10m Dec2006

Design an algorithm and draw corresponding flowchart to print the value of the number in words when the number entered is in the range of 1 to 299. 10m Dec2006 #include <stdio.h> #include <string.h> #include <stdlib.h> void main() { char num[3]; void convert_to_words(char*); clrscr(); printf(“Enter any number between 1 to 299 : “); scanf(“%s”,&num); convert_to_words(num);… Read More »

Write a program in C’ that accepts 10 words of varying length and arranges the words in the descending order of word length. Use arrays. 10m Dec2006

Write a program in C’ that accepts 10 words of varying length and arranges the words in the descending order of word length. Use arrays. 10m Dec2006 #include<stdio.h> #include<string.h> void main() { int i,j; char array[10][10],temp[10]; clrscr(); printf(“Enter ten words : \n”); for(i=0;i<10;i++) { printf(“%d : “,i+1); gets(array[i]); } for(i=0;i<10;i++) { for(j=i;j<10;j++) { if(strlen(array[i])<strlen(array[j])) {… Read More »