Born
September 9, 1941(1941-09-09)Bronxville, New York, U.S.
Died
found dead October 12, 2011(2011-10-12) (aged 70)Berkeley Heights, New Jersey, U.S.
Fields
Computer science
Institutions
Lucent TechnologiesBell Labs
Alma mater
Harvard University
Known for
ALTRANBBCPLCMulticsUnix
Notable awards
Turing AwardNational Medal of Technology
Dennis MacAlistair Ritchie (b. September 9, 1941; found dead October 12, 2011), was an American computer scientist who "helped shape the digital era." He created the C programming language and, with long-time colleague Ken Thompson, the UNIX operating system. Ritchie and Thompson received the Turing Award from the ACM in 1983, the Hamming Medal from the IEEE in 1990 and the National Medal of Technology from President Clinton in 1999. Ritchie was the head of Lucent Technologies System Software Research Department when he retired in 2007. He was the 'R' in K&R C and commonly known by his username dmr.
Background
Ritchie was born in Bronxville, New York. His father was Alistair E. Ritchie, a longtime Bell Labs scientist and co-author of The Design of Switching Circuits on switching circuit theory. He moved with his family to Summit, New Jersey, as a child, where he graduated from Summit High School.
Ritchie graduated from Harvard University with degrees in physics and applied mathematics. In 1967, he began working at the Bell Labs Computing Sciences Research Center, and in 1968, he received a PhD from Harvard under the supervision of Patrick C. Fischer, his doctoral dissertation being "Program Structure and Computational Complexity".
C and Unix
Ritchie was best known as the creator of the C programming language, a key developer of the UNIX operating system, and co-author of The C Programming Language, and was the 'R' in K&R (a common reference to the book's authors Kernighan and Ritchie). Ritchie worked together with Ken Thompson, the scientist credited with writing the original Unix; one of Ritchie's most important contributions to Unix was its porting to different machines and platforms. The C language is widely used today in application, operating system, and embedded system development, and its influence is seen in most modern programming languages. UNIX has also been influential, establishing concepts and principles that are now precepts of computing.
Ritchie was elected to the National Academy of Engineering in 1988 for "development of the 'C' programming language and for co-development of the UNIX operating system."
Awards
Turing Award
In 1983, Ritchie and Thompson jointly received the Turing Award for their development of generic operating systems theory and specifically for the implementation of the UNIX operating system. Ritchie's Turing Award lecture was titled "Reflections on Software Research".
IEEE Richard W. Hamming Medal
In 1990, both Ritchie and Thompson received the IEEE Richard W. Hamming Medal from the Institute of Electrical and Electronics Engineers (IEEE), "for the origination of the UNIX operating system and the C programming language".
Fellow of the Computer History Museum
In 1997, both Ritchie and Thompson were made Fellows of the Computer History Museum, "for co-creation of the UNIX operating system, and for development of the C programming language."
National Medal of Technology
Thompson (left) and Ritchie (center) receiving the National Medal of Technology from President Clinton in 1999. On April 21, 1999, Thompson and Ritchie jointly received the National Medal of Technology of 1998 from President Bill Clinton for co-inventing the UNIX operating system and the C programming language which, according to the citation for the medal, "led to enormous advances in computer hardware, software, and networking systems and stimulated growth of an entire industry, thereby enhancing American leadership in the Information Age".
Japan Prize
In 2011, Ritchie, along with Thompson, was awarded the Japan Prize for Information and Communications for his work in the development of the Unix operating system.
Dennis MacAlistair Ritchie the Creator of C Language
1 commentsPosted by acas arnel m. at 12:13 AM
My Project using file handling in C
6 comments#include
#include
#include
char log,sign,a;
int x,c,m,z[20];
int choice;
int main()
{
char pass[30];
char filename[30];
int balik=1;
char line1[20];
char line2[20];
char line3[20];
char line4[20];
char line5[20];
char line6[20];
int code;
char fid[20];
char fpass[20];
FILE *f;
printf("sign-in to YAHOOMAIL!\n");
printf("you are protected\n\n");
system("pause");
while(balik==1)
{
printf("enter ID:");
gets(filename);
///1
if((f=fopen(filename,"r"))!=NULL)
{
printf("error! ID exist!\n");
balik=1;
}
///1
else
{
///2
if((f=fopen(filename,"w"))==NULL)
{
printf("error ID\n");
balik=1;
}
//2
else
{
//information center
f=(fopen(filename,"w"));
printf("last name:");
gets(line1);
fprintf(f,"last name:%s\n\n",line1);
printf("first name:");
gets(line2);
fprintf(f,"first name:%s\n\n",line2);
printf("middle name:");
gets(line3);
fprintf(f,"middle name:%s\n\n",line3);
printf("age:");
gets(line4);
fprintf(f,"age:%s\n\n",line4);
printf("gender:");
gets(line5);
fprintf(f,"gender:%s\n\n",line5);
printf("Email Address:");
gets(line6);
fprintf(f,"Email Address:%s\n\n",line6);
fclose(f);
printf("PASSWORD:");
scanf("%s",pass);
f=(fopen(pass,"a"));
fclose(f);
ret:
printf("\n\nJust a couple more details...\n Type the code shown\n\n");
printf("do not input character!\n\n");
printf(" __________________\n");
printf("| |\n");
printf("| 2253028 |\n");
printf("|__________________|\n\n");
printf("type the codes:");
scanf("%d",&code);
///3
switch (code)
{
///3
case 2253028:
printf("\n\nsuccessfully signed\n\n");
system("pause");
goto alog;
///3
case 2:
printf("error");
system("cls");
goto ret;
///3
default:
system("cls");
goto ret;
}
alog:
system("cls");
for (m=0;m<=44;m++)
printf("%d",m);
printf("\n\n\n\n\n\n\n\n\n\n\n\t\t\t\tlog-in?[y/n]:");
scanf("%s",&log);
///4
switch (log)
{
///4
case 'y':
{
final:
system("cls");
printf("enter ID:");
scanf("%s",fid);
printf("enter PASSWORD:");
scanf("%s",fpass);
///5
if ((strcmp(fid,filename)==0)&&(strcmp(fpass,pass)==0))
{
main:
system("cls");
printf("\n\n\n\n\n view account[1]\n\n");
printf("military time [2]\n\n");
printf("log-out [3]\n\n\n\n\n");
printf("enter your choice:");
scanf("%d",&choice);
switch (choice)
{
case 1:
{
system("cls");
f=(fopen(filename,"r"));
fgets(line1,20,f);
fgets(line2,20,f);
fgets(line3,20,f);
fgets(line4,20,f);
fgets(line5,20,f);
fgets(line6,20,f);
printf("your account:\n\n");
puts(line1);
puts(line2);
puts(line3);
puts(line4);
puts(line5);
puts(line6);
system("pause");
goto main;
break;
}
case 2:
{
system("cls");
printf("enter your name:");
scanf("%s",z);
printf("hello %s have fun! enjoy...\n\n",z);
printf("enter your military time:");
scanf("%d",&x);
/*ACAS ARNEL M.*/
if(x==1300)
{
printf("1:00 pm");
system("cls");
system("pause");
goto main;
}
if((x>=1301)&&(x<=1399))
{
c=x-1300;
printf("1:%dpm",c);
system("pause");
goto main;
}
if(x==1400)
{
printf("2:00 pm");
system("pause");
goto main;
}
if((x>=1401)&&(x<=1499))
{
c=x-1400;
printf("2:%d pm",c);
system("pause");
goto main;
}
if(x==1500)
{
printf("3:00 pm");
system("pause");
goto main;
}
if((x>=1501)&&(x<=1599))
{
c=x-1500;
printf("3:%d pm",c);
system("pause");
goto main;
}
if(x==1600)
{
printf("4:00 pm");
system("pause");
goto main;
}
if((x>=1601)&&(x<=1699))
{
c=x-1600;
printf("4:%d pm",c);
system("pause");
goto main;
}
if(x==1700)
{
printf("5:00 pm");
system("pause");
goto main;
}
if((x>=1701)&&(x<=1799))
{
c=x-1700;
printf("5:%d pm",c);
system("pause");
goto main;
}
if(x==1800)
{
printf("6:00 pm");
system("pause");
goto main;
}
if((x>=1801)&&(x<=1899))
{
c=x-1800;
printf("6:%d pm",c);
system("pause");
goto main;
}
if(x==1900)
{
printf("7:00 pm");
system("pause");
goto main;
}
if((x>=1901)&&(x<=1999))
{
c=x-1900;
printf("7:%d pm",c);
system("pause");
goto main;
}
if(x==2000)
{
printf("8:00");
system("pause");
goto main;
}
if((x>=2001)&&(x<=2099))
{
c=x-2000;
printf("8:%d pm",c);
system("pause");
goto main;
}
if(x==2100)
{
printf("9:00 pm");
system("pause");
goto main;
}
if((x>=2101)&&(x<=2199))
{
c=x-2100;
printf("9:%d pm",c);
system("pause");
goto main;
}
if(x==2200)
{
printf("10:00 pm");
system("pause");
goto main;
}
if((x>=2201)&&(x<=2299))
{
c=x-2200;
printf("10:%d pm",c);
system("pause");
goto main;
}
if(x==2300)
{
printf("11:00 pm");
system("pause");
goto main;
}
if((x>=2301)&&(x<=2399))
{
c=x-2300;
printf("11:%d pm");
system("pause");
goto main;
}
if(x==2400)
{
printf("12:00 pm");
system("pause");
goto main;
}
if((x>=2401)&&(x<=2499))
{
c=x-2400;
printf("12:%d pm",c);
system("pause");
goto main;
}
if(x==100)
{
printf("1:00 am");
system("pause");
goto main;
}
if((x>=101)&&(x<=199))
{
c=x-100;
printf("1:%d am",c);
system("pause");
goto main;
}
if(x==200)
{
printf("2:00 am");
system("pause");
goto main;
}
if((x>=201)&&(x<=299))
{
c=x-200;
printf("2:%d am",c);
system("pause");
goto main;
}
if(x==300)
{
printf("3:00 am");
system("pause");
goto main;
}
if((x>=301)&&(x<=399))
{
c=x-300;
printf("3:%d am",c);
system("pause");
goto main;
}
if(x==400)
{
printf("4:00 am");
system("pause");
goto main;
}
if((x>=401)&&(x<=499))
{
c=x-400;
printf("4:%d am",c);
system("pause");
goto main;
}
if(x==500)
{
printf("5:00 am");
system("pause");
goto main;
}
if((x>=501)&&(x<=599))
{
c=x-500;
printf("5:%d am",c);
system("pause");
goto main;
}
if(x==600)
{
printf("6:00 am");
system("pause");
goto main;
}
if((x>=601)&&(x<=699))
{
c=x-600;
printf("6:%d am",c);
system("pause");
goto main;
}
if(x==700)
{
printf("7:00 am");
system("pause");
goto main;
}
if((x>=701)&&(x<=799))
{
c=x-700;
printf("7:%d am",c);
system("pause");
goto main;
}
if(x==800)
{
printf("8:00 am");
system("pause");
goto main;
}
if((x>=801)&&(x<=899))
{
c=x-800;
printf("8:%d am",c);
system("pause");
goto main;
}
if(x==900)
{
printf("9:00 am");
system("pause");
goto main;
}
if((x>=901)&&(x<=999))
{
c=x-900;
printf("9:%d am",c);
system("pause");
goto main;
}
if(x==1000)
{
printf("10:00 pm");
system("pause");
goto main;
}
if((x>=1001)&&(x<=1099))
{
c=x-1000;
printf("10:%d am");
system("pause");
goto main;
}
if(x==1100)
{
printf("11:00 am");
system("pause");
goto main;
}
if((x>=1101)&&(x<=1199))
{
c=x-1100;
printf("11:%d am",c);
system("pause");
goto main;
}
if(x==1200)
{
printf("12:00 pm");
system("pause");
goto main;
}
if((x>=1201)&&(x<=1299))
{
c=x-1200;
printf("12:%d pm",c);
system("pause");
goto main;
}
else
{
printf("error input! guys....\n\n\n\n");
system("pause");
goto main;
return 0;
}
goto main;
}
case 3:
{
system("cls");
printf("\n\n\nsuccessfully log-out!");
return 0;
}
default:
{
goto main;
}
}
}
///5
else
{
system("cls");
printf("user no register!\n\n");
goto final;
}
break;
}
///4
case 'n':
{
printf("bye bye.... see you soon!");
break;
}
///4
default:
{
goto alog;
}
}
//f=(fopen("password.txt","w"));
// printf("PASSWORD:");
// scanf("%s",filename);
// fclose(f);
// f=(fopen(filename,"r"));
// fgets(line,500,f);
// printf("the line you enter:");
// puts(line);
break;
}
}
}
return 0;
}
Posted by acas arnel m. at 12:56 AM
Labels: C language codes
converts text into binary using the division method through ASCII code
0 comments#include
using namespace std;
#include
#include
char *entry, letter, choice[2];
int ascii, len, binary[8], total;
void prog();
int main()
{
prog();
return 0;
}
void prog()
{
entry = new char[501];
/* entry should be dynamic, otherwise a new
string entry of 501 chars would be created
each time function is called!
Talk about memory hog! */
cout<<"Enter string to convert (up to 500 chars): "; cin.getline(entry, 500); len = strlen(entry); /* get the number of characters in entry. */ /* this loop is executed for each letter in the string. */ for(int i = 0; i
stores it backwards into the binary array. */
{
/* To get the binary code one must take the decimal number in
question, take it and divide it by two repeatedly, save
the remainder (which will become the binary number), save
the whole number, divide by two, and repeat the whole
process until 0 is reached. This if-else statement serves
this functionality, by getting the remainder of the ascii
code, storing it in the array and then dividing the int
ascii by two */
if((ascii%2)==0)
{
binary[total] = 0;
ascii = ascii/2;
total++; /* increasing by one each time will yeild the
number of numbers in the array. */
}
else
{
binary[total] = 1;
ascii = ascii/2;
total++;
}
}
total--; /* due to data type factors, the program will actually
add a 0 at the end of the array that is not supposed
to be there, decrementing total will solve this
problem, as that 0 will not be displayed. */
/* this while loop displays the binary code for that letter. */
while(total>=0)
{
cout<
total--;
}
}
delete[] entry; /* free up the memory used by entry */
cout<
cin.getline(choice,3);
if(choice[0] == '1')
prog(); /* program is recursive, it calls itself. It's kinda
like a function loop of sorts. */
else
exit(0); /* quits the program */
}
Posted by acas arnel m. at 12:54 AM
Labels: C language codes
Factorial Permutation and Combination in C
0 comments#include
int factor (int num)
{
if (num>1)
{
return (num * factor(num-1));
}
else{}
return (1);
}
int main(void)
{
int 1num,2num,permdin,permfact;
int den,comdin,comfact,sub1,sub2;
printf("Enter First Number:");
scanf("%d",&1num);
printf("%d = %d \n\n\n\n\n\n\n",1num,factor(1num));
printf("Enter Second Number:");
scanf("%d",&2num);
printf("%d = %d \n\n",2num,factor(2num));
if(1num>2num)
{
sub1=1num-2num;
permdin=factor(sub1);
permfact=(factor(1num)/permdin);
printf("Permutation = %d\n\n",permfact);
printf( "Combination : %d",factor(1num) / (factor(2num)* factor(1num-2num)));
printf("\n\n\n");
}
else
{
printf("Invalid:\n\n");
}
return 0;
}
Posted by acas arnel m. at 12:50 AM
Labels: C language codes
Calloc in C
0 comments/* SAGpa Sa bala Kan-a */
#include
#include
int main ()
{
int i,n;
int * pData;
printf ("Amount of numbers to be entered: ");
scanf ("%d",&i);
pData = (int*) calloc (i,sizeof(int));
if (pData==NULL) exit (1);
for (n=0;n
{
printf ("Enter number #%d: ",n);
scanf ("%d",&pData[n]);
}
printf ("You have entered: ");
for (n=0;n
free (pData);
return 0;
}
Posted by acas arnel m. at 12:48 AM
Labels: C language codes
Malloc in C
2 comments#include
#include
int strlen(char *s)
{
int n;
for(n=0;*s!='\0';s++)
n++;
return n;
}
int main()
{
/*char s[] = "JohnBridge my Heart";
printf("length = %d\n",strlen(s));
*/
int n;
char *s;
n = strlen("JohnBridge my Heart");
s = (char *)malloc(n*sizeof(char));
*s = "JohnBridge my Heart";
printf("length = %d\n",strlen(s));
return 0;
}
Posted by acas arnel m. at 12:46 AM
Labels: C language codes
Multiplication Table in C
0 comments#include
int main()
{
//char ans;
int column,row,i,j;
printf("rows:");
scanf("%d",&row);
printf("column:");
scanf("%d",&column);
i=0;
while(i
{
j=0;
printf("%d\t",(i+1));
while(j
{
printf("%d\t",(i+1)*(j+1));
j++;
}
printf("\n");
i++;
}
return 0;
}
Posted by acas arnel m. at 12:45 AM
Labels: C language codes
File manipulation in C
0 comments#include
#include
int main()
{
FILE *fp;
int returnvar = 1;
char ans = 'y';
char filename[20];
char statement[30];
while(returnvar!=0)
{
printf("enter filename: ");
scanf("%s",filename);
printf("\nWriting to %s...\n\n",filename);
if((fp=fopen(filename,"r"))!=NULL)
{
printf("error: file already exists\n");
returnvar = 1;
exit(1);
}
else
{
if((fp=fopen(filename,"w+"))==NULL)
{
printf("error creating file\n");
returnvar = 1;
exit(1);
}
else
{
printf("writing successful\n");
break;
}
}
}
while(ans!='n')
{
printf("enter a statement to write to file of not more than 30 characters");
scanf("%s",statement);
fprintf(fp,statement);
fprintf(fp,"\n");
printf("input another statement? ");
scanf("%c",&ans);
}
fclose(fp);
return 0;
}
Posted by acas arnel m. at 12:44 AM
Labels: C language codes
Output Random Numbers
0 comments#include
#include
#include
int x,y[5],i,temp,k;
int main(void)
{
srand(time(NULL));
for (i=1;i<=5;i++)
{
printf("%d\n",x=rand()%10);
y[i]=x;
}
printf("\n\n");
for (i=1;i<=5;i++)
{
for (k=i;k<=5;k++)
{
if (y[i]>y[k])
{
temp=y[i];
y[i]=y[k];
y[k]=temp;
}
}
}
for (i=1;i<=5;i++)
{
printf("%d\n",y[i]);
}
return(0);
}
Posted by acas arnel m. at 12:39 AM
Labels: C language codes
My final project in Assembly
0 comments;color box
model small.stack 256h
.dataa1 db" linat-ang BAKA$" a2 db" Bulalo$"a3 db" Tinulang manok$"a4 db" Linat-ang Baboy$"a5 db" 1 serve PANSIT$"a6 db" 1 serve Humba$"a7 db" 1 serve Halang2x$"converges db " GRAND ROYAL RESTAURANT$";----------------------------------------------------------------------------msg db"[1]VIEW ALL [0] exit $"
hot_soap_sub1 db " HOT SOUP 1 serve" db 0Dh,0Ah,0Ah," [a]Linat-ang BAKA=25 [c]Tinulang manok=20" db 0Dh,0Ah,0Ah," [b]Bulalo=30 [d]Linat-ang Baboy=13" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah
more_foods_sub1 db " MORE FOODS" db 0Dh,0Ah,0Ah," [e]1 serve Pancit=8 [g]1 serve Halang2x=20" db 0Dh,0Ah,0Ah," [f]1 serve Humba=25" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah ;-----------------------------------------------------------------------------sub2 db "[a] VIEW AWARDS" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah ;----------------------------------------------------------------------------detail db " Awards" db 0Dh,0Ah,0Ah," DATE Rewarded Rewards" db 0Dh,0Ah,0Ah," jan 6,2008 Best Sugbahan" db 0Dh,0Ah,0Ah," jun 13,205 Most outstanding Sugbahan" db 0Dh,0Ah,0Ah," dec 25,2006 Best FastFood" db 0Dh,0Ah,0Ah," feb 6,2001 Best Foods" db 0Dh,0Ah,0Ah," ----------------------------------------" db 0Dh,0Ah,0Ah," press any key to back to main menu$",0Ah ;----------------------------------------------------------------------------- addition db'[A]dd','$' subtraction db'[S]ub','$' multiplication db'[M]ul','$' divide db'[D]iv','$' mssg db'Enter your choice[(a)-(g)]:','$' msg1 db'Pila ra man imo paliton: PESOS ','$' msg2 db'Pila man kabuok serve?:','$' ur_money db "your money:$" sum db'Your changes is:','$' diff db'Your changes is:','$' mult db'The total is:','$' dive db'The answer is:','$'
wrong db' Invalid Input!','$' again db'Do you want to buy again[Y/N]?','$' rem db'remainder:','$'
num1 dw ? num2 dw ?subt1 db "akong bayad:$"minus db "kuhaan sa total:$" ;-------------------------------------------computations----------------------code db "MY FAVORITE LETTER IS:$"
;----------------------------------------------------------------------------
input db "Enter your choice:$";---------------------------
pawala db "error input$";--------------------------.codestart:
;--------------------clear screenmov ax, 0600hmov bh,07hmov cx,0000hmov dx,184fhint 10h;-------------------first box colorcall box_color;---------------------------
mov ax,@datamov ds,ax
mov dh,14mov dl,30mov ah,02hxor bh,bhint 10hmov dx,offset codemov ah,09hint 21h
;----------------------inputmov ah, 01hint 21hmov dl,al
;----------------------enterxor ah,ahint 16h ;----------------akong if elsecmp dl, 'A'je ada
jne startstarttt:call clrcall startfive55:call clrxor ah,ahint 16h call fivecall clr;----------location sa boxada:call clrcall box_colormov dh,4mov dl,26mov ah,02hxor bh,bhint 10hmov dx,offset msgmov ah,09hint 21h
mov dx, offset sub2mov ah, 09hint 21h
mov dh,15mov dl,28mov ah,02hxor bh,bhint 10hmov dx,offset inputmov ah,09hint 21h
;----------------------inputmov ah, 01hint 21hmov dl,al
;----------------------enterxor ah,ahint 16h
;----------------akong if elsecmp dl, '1'je five5cmp dl, '0'je humanncmp dl, 'a'je detalyeejne startt;---------------------------startt:call startdetalyee:call detailsfive5:call fivehumann:call human;--------------------------------------------details:call clrcall box_colorcall detalyecall input_key;----------------------------------------five:call clrcall box_color
mov dh,3mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset converges mov ah, 09hint 21h
mov dh,6mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset hot_soap_sub1 mov ah, 09hint 21h
mov dh,14mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset more_foods_sub1 mov ah, 09hint 21h
mov ax, @data mov ds, axchoice:mov dh,23mov dl,26mov ah,02hxor bh,bhint 10h mov ax, offset mssg call put_string
mov ah,1h int 21h
mov bl,al;--------------------------------------------------------------------------- cmp bl,'a' je aa1 cmp bl,'b' je aa2 cmp bl,'c' je aa3 cmp bl,'d' je aa4 cmp bl,'e' je aa5 cmp bl,'f' je aa6 cmp bl,'g' jne aa77jne fiveefivee:call five
aa77:call aa7 aa1:call lokmov dx, offset a1 call linka equ 25call multingmov num1, acall multiaa2:call lokmov dx, offset a2 call linkb equ 30call multingmov num1, bcall multiaa3:call lokmov dx, offset a3 call linkcc equ 20call multingmov num1, cccall multiaa4:call lokmov dx, offset a4 call linkd equ 13call multingmov num1, dcall multiaa5:call lokmov dx, offset a5 call linke equ 8call multingmov num1, ecall multiaa6:call lokmov dx, offset a6 call linkf equ 25call multingmov num1, fcall multi aa7:call lokmov dx, offset a7 call linkg equ 20call multingmov num1, gcall multilink:mov ah, 09hint 21h ret;------------------------------------------------------------ lok: mov dh,25 mov dl,26 mov ah,02h xor bh,bh int 10hret multing: mov dh,34 mov dl,26 mov ah,02h xor bh,bh int 10h ;mov ax, offset msg1 ;call put_string ;call get_numret ;mov num1, axmulti: mov dh,27 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax, offset msg2 call put_string call get_num
mov num2, ax
mov dh,29 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax, offset mult call put_string
mov cx, num2 mov ax, num1 mul cx
call put_num
jmp finish
;jmp finishfinish:
mov dh,31 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax,offset again call put_string
call get_char
mov bl,al
cmp bl,'Y' je choicee cmp bl,'y' je choicee
cmp bl,'N' je subing cmp bl,'n' je subing
mov ax,offset wrong call put_string jmp finish;-------------------------------------------------subtracting
subing: mov dh,33 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax, offset subt1 call put_string call get_num
mov num1, ax
mov dh,35 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax, offset minus call put_string call get_num
mov num2, ax mov dh,37 mov dl,26 mov ah,02h xor bh,bh int 10h mov ax, offset diff call put_string
mov ax, num1 sub ax, num2 call put_num
jmp human
;------------------------------------------------------------- choicee:call fivecall choice mij: cmp ax,num2 jb micher
sub ax,num2 inc cx jmp mij
micher: mov bx,ax
mov ax,cx call put_num
cmp bx,0 ; je finish
; mov ax,offset rem ; call put_string
mov ax,bx call put_numcho: end_else: mov ax, 4c00h int 21h
put_string: mov dx, ax mov ah, 9h int 21h ret
get_char: mov ah, 1h int 21h ret
put_char: mov dl,al mov ah, 2h int 21h ret
get_num: push bx push cx push dx
mov dx, 1 mov bx, 0 mov cx, 0 call get_char cmp al, ' ' jne newline mov dx, -1 call get_char
newline: push dx cmp al, 13 je fin_read sub al, '0' mov bl, al mov ax, 10 mul cx mov cx, ax add cx, bx call get_char read_loop: cmp al, 13 je fin_read sub al, '0' mov bl, al mov ax, 10 mul cx mov cx, ax add cx, bx call get_char jmp read_loop
fin_read: mov ax, cx pop dx cmp dx, 1 je fin_getn neg ax
fin_getn: pop dx pop cx pop bx ret
put_num: push bx push cx push dx
mov dx, 0 push dx mov cx,10 cmp ax, 0 jge calc_digits neg ax push ax mov al, ' ' call put_char pop ax
calc_digits:
div cx add dx, '0' push dx mov dx, 0 cmp ax, 0 jne calc_digits
display_loop: pop ax cmp ax, 0 je end_display_loop call put_char jmp display_loop
end_display_loop: pop dx pop cx pop bx ret;--------------------------input charmov ah, 01hint 21hmov dl,al
xor ah,ahint 16h
mov dl,al
cmp dl,'Y' je fives cmp dl,'y' je fives
cmp dl,'N' je human cmp dl,'n' je humanretfives:call five
;--------------------------------------------exit:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset pawalamov ah, 09hint 21hcall human
;-----------------sa clear screenclr: mov ax, 0600hmov bh,07hmov cx,0000hmov dx,184fhint 10hret
cr_loc:;----------cursor location ;sa boxmov dh,20mov dl,26mov ah,02hxor bh,bhint 10hret
input_key:;----------------------inputmov ah, 01hint 21hmov dl,alcall start
box_color:;-----------------box color
mov ax, 0700h ;constant 6 pataas ok ra na cyamov bh, 35h ;-------- color first color/ mov cx,0010h ;sinugdan size left sizemov dx,3544h ;--------size sa first color/main color sa right side ra ni------ ang 2c15h= ang 2 ky x2 ang pic boxint 10hret
;-----mov dx,1043h
;mov ax, 0600h;mov bh, 34h;mov cx,0010h;mov dx,3544h;int 10h;ret;----------------------------detalye:mov dh,0mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset detailmov ah, 09hint 21hret
;---------------sa terminatehuman: mov ax, 4c00hint 21h
end start
Posted by acas arnel m. at 11:21 PM
Labels: Assembly Codes
assignment in our business application
0 commentsAcas, Arnel M. Prof. Ildefe Villanueva
BSCS - II CSC 131 / TTH 5:30-7:00
1.) Spreadsheet:
A table of values arranged in rows and columns. Each value can have a predefined relationship to the other values. If you change one value, therefore, you may need to change other values as well.
2.) Parts of the spreadsheet:
Menu bars
Toolbars
Column and row labels
Formula Bar
Sheet tabs
Work Space
Cells
Active cell
Mouse pointer
3.) What is MS Excel?
Microsoft Excel (full name Microsoft Office Excel) is a proprietary spreadsheet application written and distributed by Microsoft for Microsoft Windows and Mac OS X. It features calculation, graphing tools, pivot tables and, except for Excel 2008 for Mac OS X, a macro programming language called VBA (Visual Basic for Applications). It is overwhelmingly the dominant spreadsheet application available for these platforms and has been so since version 5 in 1993[citation needed], and is bundled as part of Microsoft Office. Excel is one of the most popular microcomputer applications to date.
4.) Features of MS Excel 2003
MS Excel 2003 is a Windows-based application package that can be used to automate tasks such as calculation and analysis of data, automate financial statements, business forecasting, transaction registers, inventory control, etc. It provides multiple facilities, such as making graphs and charts, analyzing situations, and helps users at the managerial level in taking decisions. The features provided by Excel are very useful for managers as well as the supervisors in any type of organization and help them to execute their complex tasks with a minimum effort. MS Excel can be customized in a way that suits a user to achieve his goal. It is extensively used in financial organizations. The features of MS Excel are as follows:
Workbooks: A document in MS Excel is called a workbook. Each workbook contains sixteen worksheets by default. A user can change this number by resetting the default options. Worksheets within workbooks make it easy to bind files of related information. When a user opens a workbook, he can use all the worksheets to perform a task. To create a workbook, a user will have to select the new command from the File menu. To open an existing workbook, a user will have to select the Open option from the File menu. A user can insert a worksheet between two worksheets by choosing the Worksheet option from the Insert menu.
Using keyboard: The following table provides different keyboard shortcuts for selecting a row, column, current cell, worksheet, etc.
A user can perform various kinds of entries in a cell. He can enter text, number, data, and time in a cell. He can also enter some special characters such as $ % + - / ( ). He can also enter date and time in a cell. He can select different formats for date and time according to his own requirements.
Entering Data in Series: A user can fill a range of cells either with the same value or with the series of values. This can be done using the Auto fill handle (Small Square on the bottom-right corner of the active cell).
Cell References: MS Excel provides three types of cell references: relative, absolute, and mixed. Relative references refer to the cell relative to the given position. Absolute references refer to the specific cell irrespective of the position of the formula. The '$' sign is used to denote an absolute reference. Mixed references are a combination of both relative and absolute references. It has one absolute co-ordinate and one relative co-ordinate. $CI and C$1 are both examples of mixed references.
Inserting or Deleting Rows and Columns: MS Excel provides the facility to insert rows or columns into the existing worksheet. Inserting a row of data shifts the rest of the rows down and removes the last row of the worksheet. Similarly, inserting a column shifts the rest of the columns to the right and deletes the rightmost column. This occurs because the total number of rows and columns remain the same in any case.
MS Excel provides several formatting features that enhance the appearance of the data, which is presented in the worksheets. Some of them are described as follows: MS Excel allows setting up a page before printing. To set up a page, a user will have to open the File menu and click on the Page Setup. The Page Setup dialog box will appear that will allow the user to set the paper size, orientation of the data, scaling of the area, set the left, right, bottom, and top margin, set the header and the footer, etc.
MS Excel provides the auto fit selection that adjusts the width of the column according to the widest entry in that column. A user can hide or unhide certain rows or columns. He can also provide the default column standard width.
MS Excel allows a user to align the characters in different ways by using the Alignment tab page of the Format Cells dialog box. The dialog box provides a number of alignment options.
Horizontal Alignment options:
General: The text is left aligned and the numbers are right aligned. This is the default status.
Left: Aligns the contents to the left of the cell.
Center: Aligns the cell contents to the center of the cell.
Right: Aligns the contents to the right of the cell.
Fill: Fills the selected cells with the single character.
Justify: This option is selected with multiple lines of text as it wraps the contents from left to right.
Vertical Alignment options:
Top: Aligns the text at the top of the cell.
Center: Places the text in the center of the cell.
Bottom: Aligns the text on the bottom of the cell.
Justify: Wraps the text from top to bottom.
Controls: The controls are the special objects, which enhance user interface and facilitate user input. MS Excel provides several custom controls such as list boxes, check boxes, and dialog boxes, etc. A large number of toolbars are found in the View menu. Users can add a toolbar or a number of toolbars into the working document depending upon the work involved and use different controls in their documents.
Functions and formulas: The built-in formulas are called functions. MS Excel provides analyzing data and manipulating text by using different functions. Users can easily calculate percentage, interest, average, etc. by using built-in functions. This can be done either by typing in the function-based formulas or by using function wizards. Formulas are widely used in simple computing (such as addition, subtraction, multiplication and division) and advanced computing. They provide the power to analyze data extensively.
Manual: In this type of calculation, the recalculation of the complete worksheet is performed by pressing the F9 key. This option can be selected on the Calculation tab page of the Options dialog box, which is opened by choosing Options from the Tools menu.
Charts: One of the most important features of MS Excel is a chart. MS Excel allows users to view data entered as tables in a graphical form as charts, which helps a user to easily understand, analyze, and compare data. Excel allows its users to create either two-dimensional charts or three-dimensional charts. A user can enhance the chart by adding chart items, such as data labels, a legend, titles, text, and gridlines. He can also do formatting on these items by using colors, alignment, fonts, and other formatting attributes. MS Excel also allows users to view charts along with the data by using embedded charts. These charts are included in the worksheet and can be copied, moved, and resized in the same way as can be done with any other graphical object.
Database: Data are raw facts, information is processed data, and a database is an organized collection of information. Every organization heavily depends upon databases to store, retrieve, and maintain different kinds of data. MS Excel provides all this in the form of its database feature. In MS Excel, database can be created in two ways:
Enter the data in the form of table in the worksheet.
Auto-calculation: MS Excel spreadsheet allows a user to automatically recalculate the whole worksheet every time a change is made in a single cell. There are basically two kinds of recalculations.
Automatic: In this type of calculation, the change in the value of the cell automatically recalculates the whole worksheet.
Use the Data Form command
Records can be inserted, deleted, and sorted by using the Data menu.
With the above-described features of MS Excel, users can perform almost all the operations they want in a very efficient and easy way. Its advanced features have made it the first choice for professionals working in a financial organization to perform their lengthy tasks in an easy way and in a quick manner. Therefore, MS Excel has become the most preferred choice for most of the users as well as professionals throughout the world.
5.) What are a Cell, Workbook, and Worksheet?
Cell:
A cell is a single location on a worksheet in which data is stored. A cell is referred to by its unique address, or cell reference, which is composed of the coordinates of the intersection of a column and a row. To identify a cell, specify the column letter immediately followed by the row number.
Workbook:
When Excel starts, it creates a new empty workbook (Book 1) that displays the active worksheet (Sheet1). The workbook is like a notebook. The workbook contains sheets, called worksheets. Each worksheet can contain sets of data and charts. Each sheet name appears on a sheet tab at the bottom of the workbook. You access different worksheets by clicking the sheet tab or using the tab scrolling buttons to the left of the sheet tabs. A new workbook opens with 3 worksheets. However, the number of worksheets per workbook is limited only by the amount of memory on your computer. Several workbooks may be open at one time.
Worksheet:
The worksheet is organized into a rectangular grid with 256 columns and 65,536 rows. A column letter above the grid, also called a column heading, identifies each column with the letters A through IV. A row number on the left side of the grid, also called the row heading, identifies each row with the numbers 1 through 65536.
6.) How many cells are there in MS Excel Worksheet?
A maximum of 32,000 characters can be entered in a cell. Of the 16,777,216 possible cells in a worksheet, only a small fraction of the active worksheet displays on the screen at one time. You view the portion of the worksheet on the screen in a worksheet window. Below and to the right of the worksheet window are scroll bars, scroll arrows, and scroll boxes which you can use to move around the active worksheet
7.) Illustrate the parts of MS Excel Windows:
8.) What are the common built-in commands of MS Excel?
The common built-in commands in MSExcel are the following:
§ AVERAGE ( ) function - we find the class's average (or arithmetic mean) grade and its syntax is =AVERAGE (number1, number2..).
§ MEDIAN ( ) function - the median gives the middle number in a set of numbers and its syntax is =MEDIAN (number1, number2..).
§ MODE ( ) function - mode gives the most frequently occurring value of a set of numbers and its syntax is =MODE (number1, number2..).
§ COUNT ( ) function - gives the number of cells that contain numbers. Its syntax is =COUNT (value1, value2..).
§ MAX ( ) function returns the largest value in a set of numbers. Its syntax is =MAX (number1, number2..).
§ MIN ( ) function returns the smallest value in a set of numbers. Its syntax is =MIN (number1, number2..)
The SUM Function
To add a column or a row of numbers follow the steps below:
Click on an empty cell. In the above example, we chose cell F1 in which to enter our formula.
With your keyboard type the equal sign (=)
Begin the function by typing SUM (* don’t forget to open the parentheses!
Either type A1:E1 or use your mouse to highlight cells A1, B1, C1, D1 and E1
Complete the function with a closing parentheses by typing )
Press the
Note the sum of the numbers is displayed in cell F1 and the formula can be found in the formula bar.
The AVERAGE Function
To average a column or a row of numbers follow the steps below:
Click on an empty cell. In the above example, we chose cell F1 in which to enter our formula.
With your keyboard type the equal sign (=)
Begin the function by typing AVERAGE( * Don't forget to open the parentheses!
Either type A1:E1 or use your mouse to highlight cells A1, B1, C1, D1 and E1
Complete the function with a closing parentheses by typing )
Press the
Note the average of the numbers is displayed in cell F1 and the formula can be found in the formula bar.
The SQRT (Square Root) Function
To find the square root of a number located within a worksheet cell follow the steps below:
Click on an empty cell. In the above example, we chose cell B2 in which to enter our formula.
With your keyboard type the equal sign (=)
Begin the function by typing SQRT( * Don't forget to open the parentheses!
Either type B1 or use your mouse to click on cell B1
Complete the function with a closing parentheses by typing )
Press the
9.) Name at least five (5) charts of MS Excel and describe each briefly.
Floating Column Charts
Some kinds of data look very nice and are easily understood in the form of a "floating" column or bar, in which the column floats in the chart, spanning a region from a minimum value to a maximum value.
Special Format for Minimum and Maximum
Ever want to apply special formatting to just a certain point? This example shows you how to highlight the minimum and maximum values of a series by using a different marker for each, and data labels. We'll accomplish this with two extra series in the chart, one for minimum and one for maximum.
Use an Arrow to Indicate Special Points
People often want to use an arrow or other symbol to indicate a point in a chart. If you draw an arrow, or any AutoShape, in a chart, it is not in any way tied to the data or to the chart axes, so it will not move to keep up with a point as the axes change or the chart resizes. Even if the chart does not change, an AutoShape is not guaranteed to be in exactly the same position the next time the file is opened. This technique shows how to attach an indicator (arrow) to a point by creating custom markers for the Min and Max series.
Horizontally Banded Chart Background
A chart could be made more informative by selectively shading regions of the background with different colors. For example, a run chart may show colored bands to indicate standard deviations of a process value from the mean. Excel only provides the ability to add one color to the background, but multiple colors can be added by creating a combination chart with added area chart series colored as desired. This tutorial shows how to construct such a chart.
Make Gridlines Square
A common question people ask is "How do I format my chart so its gridlines make a square pattern?" Excel has no setting that forces equally spaced horizontal and vertical gridlines or horizontal and vertical axis ticks, but you can achieve this effect using VBA. Below is a chart after making the appropriate scale adjustment.
Posted by acas arnel m. at 10:48 PM
sample undone sub menu w/ color txt, color box in assembly
0 commentsmodel small.stack 100h.data
cr equ 13lf equ 10msg db cr,lf,"enter ur choice: [1-5]$"una db cr,lf,"one$"duha db cr,lf,"two$"tulo db cr,lf,"three$"upat db cr,lf,"four$"lima db cr,lf,"five$"pawala db cr,lf,"error input$".codestart:human: mov ax,@data mov ds,ax
mov dx,offset msg mov ah,09h int 21h
mov ax,0600hmov bh,00hmov cx, 221bhmov dx,1e33hint 10h
mov ax, 0600hmov bh, 42hmov cx,1019hmov dx,1c31hint 10h
;input mov ah, 01h int 21h mov dl,al
;enter xor ah,ah int 16h
cmp dl, '1' je one
cmp dl, '2' je two
cmp dl, '3' je three
cmp dl, '4' je four
cmp dl, '5' je five
jne exit
one: mov dx, offset una mov ah, 09h int 21h je human
two: mov dx, offset duha mov ah, 09h int 21h je human three: mov dx, offset tulo mov ah, 09h int 21h je human
four: mov dx, offset upat mov ah, 09h int 21h je human
five: mov dx, offset lima mov ah, 09h int 21h je human
exit: mov dx, offset pawala mov ah, 09h int 21h je human
mov ax, 4c00h int 21h
end start
Posted by acas arnel m. at 10:46 PM
Labels: Assembly Codes
cd rental/cellphone repair in w/ sub menu, txt color, box color assembly code
0 comments.model small.stack.datadesserts db 0Ah," cd rental/cellphone repair" db 0Dh,0Ah,0Ah," 1.Movie 2.Music" db 0Dh,0Ah," 3. cellphone accesories$",0Ah,0Ahmovie db 0Ah," cd rental/cellphone accesories" db 0Dh,0Ah,0Ah," 1.Action 2.comedy$",0Ah,0Ahmusic db 0Ah," cd rental/cellphone accesories" db 0Dh,0Ah,0Ah," 1.Audio 2.videoke$",0Ah,0Ahphone db 0Ah," cd rental/cellphone accesories" db 0Dh,0Ah,0Ah," 1. Nokia $" db 0Dh,0Ah," 2.Apple$"say db 0Ah," cd rental/cellphone repair " db 0Dh,0Ah,0Ah," Sorry You Input " db 0Dh,0Ah," A Wrong Choice.$"kuha db 0Dh,0Ah," cd rental/cellphone repair" db 0Dh,0Ah,0Ah," 1.Abang 2.Uli" db 0Dh,0Ah," 3.Repair$"choice db 0Dh,0Ah," Enter Your Choice:$"choice1 db 0Dh,0Ah," Enter Your Choice:$"choice2 db 0Dh,0Ah," Enter Your Choice:$"choice3 db 0Dh,0Ah," Enter Your Choice:$"
.codestart:mov ax,@datamov ds,ax
call menmov dx, offset dessertscall osmov dx, offset choicecall oscall iscmp bl,'1'je usacmp bl,'2'je duhacmp bl,'3'je tulojne inv
usa:call men1mov dx,offset moviecall osmov dx, offset choice1call oscall iscmp bl,'1'je pilicmp bl,'2'je pilijne inv
duha:call men1mov dx,offset musiccall osmov dx, offset choice1call oscall iscmp bl,'1'je pilicmp bl,'2'je pilijne inv
tulo:call men1mov dx,offset phonecall osmov dx, offset choice2call oscall iscmp bl,'1'je pilicmp bl,'2'je pilijne inv
pili:call men2mov dx,offset kuhacall osmov dx,offset choice3call oscall isjmp exit
inv:call men1mov dx,offset saycall osjmp exit
os:mov ah,09hint 21hret
is:mov ah,01hint 21hmov bl,alret
men:mov ax,0600hmov bh,45h;dmov cx,0303hmov dx,0B1Fh;Aint 10h
mov ah,02hmov bh,0ahmov cx,0505hmov dx,0505hint 10hret
men1:mov ax,0600hmov bh,5Dhmov cx,0A0Ahmov dx,1027hint 10h
mov ah,02hmov bh,00hmov cx,0A0Ahmov dx,0A0Ahint 10hret
men2:mov ax,0600hmov bh,7Dhmov cx,0F40hmov dx,1725hint 10hmov ah,02hmov bh,00hmov cx,0F40hmov dx,0F40hint 10hret
exit:mov ax,4c00hint 21hend start
Posted by acas arnel m. at 10:44 PM
Labels: Assembly Codes
sample sub menu of assembly w/ colors, color box, color txt,sub menu. etc.
0 comments;color box
model small.stack 100h.data
;----------------------------------------------------------------------------msg db " STORE INVENTORY" db 0Dh,0Ah,0Ah," [1]can goods [2]softdrinks" db 0Dh,0Ah,0Ah," [3]rices [4]noodles" db 0Dh,0Ah,0Ah," [0] exit $",0Ah cangoods_sub1 db " CAN GOODS" db 0Dh,0Ah,0Ah," 555 TUNA CENTURY TUNA" db 0Dh,0Ah,0Ah," CORNBEEF FAMILY BRAND SARDINES" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah softdrinks_sub1 db " SOFTDRINKS" db 0Dh,0Ah,0Ah," COKE 7 UP" db 0Dh,0Ah,0Ah," PEPSI SPRITE" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah rices_sub1 db " RICES" db 0Dh,0Ah,0Ah," BALIKATAN WHITE CORN" db 0Dh,0Ah,0Ah," NFA YELLOW CORN" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah noodles_sub1 db " NOODLES" db 0Dh,0Ah,0Ah," LUCKY ME MAMI MAGGI" db 0Dh,0Ah,0Ah," PANCIT CANTON LOMI NOODLES" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah ;-----------------------------------------------------------------------------sub2 db " [1] BACK TO MAIN MENU [2] DETAILS" db 0Dh,0Ah,0Ah," ----------------------------------------$",0Ah ;----------------------------------------------------------------------------detail db " EXPIRATION" db 0Dh,0Ah,0Ah," DATE EXPIRE ITEM" db 0Dh,0Ah,0Ah," jan 6,2010 LOMI NOODLES" db 0Dh,0Ah,0Ah," jun 13,2012 555 TUNA" db 0Dh,0Ah,0Ah," dec 25,2009 7 UP" db 0Dh,0Ah,0Ah," feb 6,2029 CENTURY TUNA" db 0Dh,0Ah,0Ah," ----------------------------------------" db 0Dh,0Ah,0Ah," press any key to back to main menu$",0Ah ;-----------------------------------------------------------------------------input db "Enter your choice:$";---------------------------
pawala db "error input$";--------------------------.codestart:
;--------------------clear screenmov ax, 0600hmov bh,07hmov cx,0000hmov dx,184fhint 10h;-------------------first box colorcall box_color;---------------------------
mov ax,@datamov ds,ax
;----------cursor location sa box
mov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx,offset msgmov ah,09hint 21h
mov dh,13mov dl,28mov ah,02hxor bh,bhint 10hmov dx,offset inputmov ah,09hint 21h
;----------cursor location sa txtmov dh,13mov dl,46mov ah,02hxor bh,bhint 10h
;----------------------inputmov ah, 01hint 21hmov dl,al
;----------------------enterxor ah,ahint 16h
;----------------akong if elsecmp dl, '1'je one1
cmp dl, '2'je two2
cmp dl, '3'je three3
cmp dl, '4'je four4cmp dl, '0'je humann
cmp dl, '0'jne start;---------------------------one1:call onetwo2:call twothree3:call threefour4:call fourhumann:call human;---------------------------one:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset cangoods_sub1mov ah, 09hint 21hmov dh,9mov dl,20mov ah,02hxor bh,bhint 10hmov dx, offset sub2mov ah, 09hint 21hmov dh,13mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset inputmov ah, 09hint 21h
;--------------------------input charmov ah, 01hint 21hmov dl,al
xor ah,ahint 16h;------------------------------------ if elsecmp dl, '1'je back2cmp dl, '2'je detaill2jne one;---------------------------------back2:call startdetaill2:call clrcall box_colorcall detalyecall input_key;------------------------------
two:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset softdrinks_sub1mov ah, 09hint 21hmov dh,9mov dl,20mov ah,02hxor bh,bhint 10hmov dx, offset sub2mov ah, 09hint 21hmov dh,13mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset inputmov ah, 09hint 21h;--------------------------input charmov ah, 01hint 21hmov dl,alxor ah,ahint 16h;------------------------------------ if elsecmp dl, '1'je back3cmp dl, '2'je detaill3jne two;---------------------------------back3:call startdetaill3:call clrcall box_colorcall detalyecall input_key;----------------------------------three:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset rices_sub1mov ah, 09hint 21hmov dh,9mov dl,20mov ah,02hxor bh,bhint 10hmov dx, offset sub2mov ah, 09hint 21hmov dh,13mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset inputmov ah, 09hint 21h;--------------------------input charmov ah, 01hint 21hmov dl,al
xor ah,ahint 16h;------------------------------------ if elsecmp dl, '1'je back4cmp dl, '2'je detaill4jne three;---------------------------------back4:call startdetaill4:call clrcall box_colorcall detalyecall input_key;---------------------------------------four:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset noodles_sub1mov ah, 09hint 21hmov dh,9mov dl,20mov ah,02hxor bh,bhint 10hmov dx, offset sub2mov ah, 09hint 21hmov dh,13mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset inputmov ah, 09hint 21h;--------------------------input charmov ah, 01hint 21hmov dl,al
xor ah,ahint 16h;------------------------------------ if elsecmp dl, '1'je back5cmp dl, '2'je detaill5jne four;---------------------------------back5:call startdetaill5:call clrcall box_colorcall detalyecall input_key;--------------------------------------------exit:call clrcall box_colormov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset pawalamov ah, 09hint 21hcall human
;-----------------sa clear screenclr: mov ax, 0600hmov bh,07hmov cx,0000hmov dx,184fhint 10hret
cr_loc:;----------cursor location ;sa boxmov dh,20mov dl,26mov ah,02hxor bh,bhint 10hret
input_key:;----------------------inputmov ah, 01hint 21hmov dl,alcall start
box_color:;-----------------box color
mov ax, 0600h ;constantmov bh, 34h ;-------- color first color/ mov cx,0010h ;sinugdan size left sizemov dx,1043h ;--------size sa first color/main color sa right side ra ni------ ang 2c15h= ang 2 ky x2 ang pic boxint 10hret
;mov ax, 0600h;mov bh, 34h;mov cx,1019h;mov dx,1c25h;int 10h;ret;----------------------------detalye:mov dh,2mov dl,26mov ah,02hxor bh,bhint 10hmov dx, offset detailmov ah, 09hint 21hret;---------------sa terminatehuman: mov ax, 4c00hint 21h
end start
Posted by acas arnel m. at 10:37 PM
Labels: Assembly Codes
critical analysist of “How my Brother Leon Brought Home a Wife”
24 commentsA Critical Analysis on
“How my Brother Leon Brought Home a Wife”
Submitted to: Submitted by:
Prof. Bernadette Yap Araula
Acas Arnel M.
Litt. 114\ 8:30-10 AM
Characters:
· Baldo - He was one of the main characters in the short story. He was
·
· Maria - She was a beautiful and lovely. Her forehead was on a level with his mouth, her nails were long, but they were not painted, and have a small dimple appeared momentarily high up on her right cheek. She was tall and very still. Her fragrance was like a morning when papayas are in bloom.
· Labang – The bull of Leon and Baldo.
· Father – He was mildest – tempered, gentlest man. He was the father of Baldo and Leon.
· Mother – He was the mother of Baldo and Leon.
· Aurelia – She was the sister of Baldo and Leon.
Summary / Synopsis:
Maria was a wife of
Characterization:
Baldo is the narrator of the story because he is the one who relates us what happened to the story. Were Baldo is the younger brother of
Settings:
The setting of the story was in
Plot:
The plot is compose of inciting action, rising action, climax, falling action, and conclusion. The inciting action was when “She stepped down to the Carretela of Ca Celin with a quick, delicate grace. She look lovely, she was tall. She looked up to my brother with a smile, and her forehead was on level with his mouth.” The rising action was when they took the dry bed of Waig as a substitute of passing the Camino Real and it was the wish of there father to go by Waig. The climax of the story was when Maria told
Themes:
The theme of the story is Love makes Maria and Leon go straight whatever struggles come will be ignore to them. I don’t know if there relationship will last long because Maria is a city girl while
Reactions of the story:
My reaction of the story is the story is good and it reflects to the modern youth even if the story is very old. I describe Maria as an example of Filipino women and also her attitude as a “mahinhin”. The couple Leon and Maria faces many trials while in traveled to Nagrebcan. Even though, Maria passed those trials. So, therefore Maria is very understanding kind of girl. The story talks about the characteristic of Maria, her attitude, her looks, how she talks and the way she handle the situation that riding a bull and passed through Waig. Therefore, basically a woman creates for men.
Posted by acas arnel m. at 5:22 AM
Labels: Short story
How my brother loen brought home a wife
0 commentsHow My Brother Leon Brought Home A Wife
(American Colonial Literature)By Manuel E. Arguilla
She stepped down from the carretela of Ca Celin with a quick, delicate grace. She was lovely. SHe was tall. She looked up to my brother with a smile, and her forehead was on a level with his mouth. "You are Baldo," she said and placed her hand lightly on my shoulder. Her nails were long, but they were not painted. She was fragrant like a morning when papayas are in bloom. And a small dimple appeared momently high on her right cheek. "And this is Labang of whom I have heard so much." She held the wrist of one hand with the other and looked at Labang, and Labang never stopped chewing his cud. He swallowed and brought up to his mouth more cud and the sound of his insides was like a drum. I laid a hand on Labang's massive neck and said to her: "You may scratch his forehead now."She hesitated and I saw that her eyes were on the long, curving horns. But she came and touched Labang's forehead with her long fingers, and Labang never stopped chewing his cud except that his big eyes half closed. And by and by she was scratching his forehead very daintily. My brother Leon put down the two trunks on the grassy side of the road. He paid Ca Celin twice the usual fare from the station to the edge of Nagrebcan. Then he was standing beside us, and she turned to him eagerly. I watched Ca Celin, where he stood in front of his horse, and he ran his fingers through its forelock and could not keep his eyes away from her.
"Maria---" my brother Leon said. He did not say Maring. He did not say Mayang. I knew then that he had always called her Maria and that to us all she would be Maria; and in my mind I said 'Maria' and it was a beautiful name. "Yes, Noel."Now where did she get that name? I pondered the matter quietly to myself, thinking Father might not like it. But it was only the name of my brother Leon said backward and it sounded much better that way. "There is Nagrebcan, Maria," my brother Leon said, gesturing widely toward the west. She moved close to him and slipped her arm through his. And after a while she said quietly. "You love Nagrebcan, don't you, Noel?"Ca Celin drove away hi-yi-ing to his horse loudly. At the bend of the camino real where the big duhat tree grew, he rattled the handle of his braided rattan whip against the spokes of the wheel. We stood alone on the roadside. The sun was in our eyes, for it was dipping into the bright sea. The sky was wide and deep and very blue above us: but along the saw-tooth rim of the Katayaghan hills to the southwest flamed huge masses of clouds. Before us the fields swam in a golden haze through which floated big purple and red and yellow bubbles when I looked at the sinking sun. Labang's white coat, which I had wshed and brushed that morning with coconut husk, glistened like beaten cotton under the lamplight and his horns appeared tipped with fire.
He faced the sun and from his mouth came a call so loud and vibrant that the earth seemed to tremble underfoot. And far away in the middle of the field a cow lowed softly in answer. "Hitch him to the cart, Baldo," my brother Leon said, laughing, and she laughed with him a big uncertainly, and I saw that he had put his arm around her shoulders. "Why does he make that sound?" she asked. "I have never heard the like of it.""There is not another like it," my brother Leon said. "I have yet to hear another bull call like Labang. In all the world there is no other bull like him."She was smiling at him, and I stopped in the act of tying the sinta across Labang's neck to the opposite end of the yoke, because her teeth were very white, her eyes were so full of laughter, and there was the small dimple high up on her right cheek. "If you continue to talk about him like that, either I shall fall in love with him or become greatly jealous."My brother Leon laughed and she laughed and they looked at each other and it seemed to me there was a world of laughter between them and in them. I climbed into the cart over the wheel and Labang would have bolted, for he was always like that, but I kept a firm hold on his rope. He was restless and would not stand still, so that my brother Leon had to say "Labang" several times. When he was quiet again, my brother Leon lifted the trunks into the cart, placing the smaller on top. She looked down once at her high-heeled shoes, then she gave her left hand to my brother Leon, placed a foot on the hub of the wheel, and in one breath she had swung up into the cart. Oh, the fragrance of her. But Labang was fairly dancing with impatience and it was all I could do to keep him from running away. "Give me the rope, Baldo," my brother Leon said. "Maria, sit down on the hay and hold on to anything." Then he put a foot on the left shaft and that instand labang leaped forward. My brother Leon laughed as he drew himself up to the top of the side of the cart and made the slack of the rope hiss above the back of labang. The wind whistled against my cheeks and the rattling of the wheels on the pebbly road echoed in my ears. She sat up straight on the bottom of the cart, legs bent togther to one side, her skirts spread over them so that only the toes and heels of her shoes were visible. her eyes were on my brother Leon's back; I saw the wind on her hair. When Labang slowed down, my brother Leon handed to me the rope. I knelt on the straw inside the cart and pulled on the rope until Labang was merely shuffling along, then I made him turn around. "What is it you have forgotten now, Baldo?" my brother Leon said. I did not say anything but tickled with my fingers the rump of Labang; and away we went---back to where I had unhitched and waited for them. The sun had sunk and down from the wooded sides of the Katayaghan hills shadows were stealing into the fields. High up overhead the sky burned with many slow fires. When I sent Labang down the deep cut that would take us to the dry bed of the Waig which could be used as a path to our place during the dry season, my brother Leon laid a hand on my shoulder and said sternly: "Who told you to drive through the fields tonight?"His hand was heavy on my shoulder, but I did not look at him or utter a word until we were on the rocky bottom of the Waig. "Baldo, you fool, answer me before I lay the rope of Labang on you. Why do you follow the Wait instead of the camino real?"His fingers bit into my shoulder. "Father, he told me to follow the Waig tonight, Manong."Swiftly, his hand fell away from my shoulder and he reached for the rope of Labang. Then my brother Leon laughed, and he sat back, and laughing still, he said: "And I suppose Father also told you to hitch Labang to the cart and meet us with him instead of with Castano and the calesa."Without waiting for me to answer, he turned to her and said, "Maria, why do you think Father should do that, now?" He laughed and added, "Have you ever seen so many stars before?"I looked back and they were sitting side by side, leaning against the trunks, hands clasped across knees. Seemingly, but a man's height above the tops of the steep banks of the Wait, hung the stars. But in the deep gorge the shadows had fallen heavily, and even the white of Labang's coat was merely a dim, grayish blur. Crickets chirped from their homes in the cracks in the banks. The thick, unpleasant smell of dangla bushes and cooling sun-heated earth mingled with the clean, sharp scent of arrais roots exposed to the night air and of the hay inside the cart. "Look, Noel, yonder is our star!" Deep surprise and gladness were in her voice. Very low in the west, almost touching the ragged edge of the bank, was the star, the biggest and brightest in the sky. "I have been looking at it," my brother Leon said. "Do you remember how I would tell you that when you want to see stars you must come to Nagrebcan?""Yes, Noel," she said. "Look at it," she murmured, half to herself. "It is so many times bigger and brighter than it was at Ermita beach.""The air here is clean, free of dust and smoke.""So it is, Noel," she said, drawing a long breath. "Making fun of me, Maria?"She laughed then and they laughed together and she took my brother Leon's hand and put it against her face. I stopped Labang, climbed down, and lighted the lantern that hung from the cart between the wheels. "Good boy, Baldo," my brother Leon said as I climbed back into the cart, and my heart sant. Now the shadows took fright and did not crowd so near. Clumps of andadasi and arrais flashed into view and quickly disappeared as we passed by. Ahead, the elongated shadow of Labang bobbled up and down and swayed drunkenly from side to side, for the lantern rocked jerkily with the cart. "Have we far to go yet, Noel?" she asked. "Ask Baldo," my brother Leon said, "we have been neglecting him.""I am asking you, Baldo," she said. Without looking back, I answered, picking my words slowly: "Soon we will get out of the Wait and pass into the fields. After the fields is home---Manong.""So near already."I did not say anything more because I did not know what to make of the tone of her voice as she said her last words. All the laughter seemed to have gone out of her. I waited for my brother Leon to say something, but he was not saying anything. Suddenly he broke out into song and the song was 'Sky Sown with Stars'---the same that he and Father sang when we cut hay in the fields at night before he went away to study. He must have taught her the song because she joined him, and her voice flowed into his like a gentle stream meeting a stronger one. And each time the wheels encountered a big rock, her voice would catch in her throat, but my brother Leon would sing on, until, laughing softly, she would join him again. Then we were climbing out into the fields, and through the spokes of the wheels the light of the lantern mocked the shadows. Labang quickened his steps. The jolting became more frequent and painful as we crossed the low dikes. "But it is so very wide here," she said. The light of the stars broke and scattered the darkness so that one could see far on every side, though indistinctly. "You miss the houses, and the cars, and the people and the noise, don't you?" My brother Leon stopped singing. "Yes, but in a different way. I am glad they are not here."With difficulty I turned Labang to the left, for he wanted to go straight on. He was breathing hard, but I knew he was more thirsty than tired. In a little while we drope up the grassy side onto the camino real. "---you see," my brother Leon was explaining, "the camino real curves around the foot of the Katayaghan hills and passes by our house. We drove through the fields because---but I'll be asking Father as soon as we get home.""Noel," she said. "Yes, Maria.""I am afraid. He may not like me.""Does that worry you still, Maria?" my brother Leon said. "From the way you talk, he might be an ogre, for all the world. Except when his leg that was wounded in the Revolution is troubling him, Father is the mildest-tempered, gentlest man I know."We came to the house of Lacay Julian and I spoke to Labang loudly, but Moning did not come to the window, so I surmised she must be eating with the rest of her family. And I thought of the food being made ready at home and my mouth watered. We met the twins, Urong and Celin, and I said "Hoy!" calling them by name. And they shouted back and asked if my brother Leon and his wife were with me. And my brother Leon shouted to them and then told me to make Labang run; their answers were lost in the noise of the wheels. I stopped labang on the road before our house and would have gotten down but my brother Leon took the rope and told me to stay in the cart. He turned Labang into the open gate and we dashed into our yard. I thought we would crash into the camachile tree, but my brother Leon reined in Labang in time. There was light downstairs in the kitchen, and Mother stood in the doorway, and I could see her smiling shyly. My brother Leon was helping Maria over the wheel. The first words that fell from his lips after he had kissed Mother's hand were: "Father... where is he?""He is in his room upstairs," Mother said, her face becoming serious. "His leg is bothering him again."I did not hear anything more because I had to go back to the cart to unhitch Labang. But I hardly tied him under the barn when I heard Father calling me. I met my brother Leon going to bring up the trunks. As I passed through the kitchen, there were Mother and my sister Aurelia and Maria and it seemed to me they were crying, all of them. There was no light in Father's room. There was no movement. He sat in the big armchair by the western window, and a star shone directly through it. He was smoking, but he removed the roll of tobacco from his mouth when he saw me. He laid it carefully on the windowsill before speaking. "Did you meet anybody on the way?" he asked. "No, Father," I said. "Nobody passes through the Waig at night."He reached for his roll of tobacco and hithced himself up in the chair. "She is very beautiful, Father.""Was she afraid of Labang?" My father had not raised his voice, but the room seemed to resound with it. And again I saw her eyes on the long curving horns and the arm of my brother Leon around her shoulders. "No, Father, she was not afraid.""On the way---""She looked at the stars, Father. And Manong Leon sang.""What did he sing?""---Sky Sown with Stars... She sang with him."He was silent again. I could hear the low voices of Mother and my sister Aurelia downstairs. There was also the voice of my brother Leon, and I thought that Father's voice must have been like it when Father was young. He had laid the roll of tobacco on the windowsill once more. I watched the smoke waver faintly upward from the lighted end and vanish slowly into the night outside. The door opened and my brother Leon and Maria came in. "Have you watered Labang?" Father spoke to me. I told him that Labang was resting yet under the barn. "It is time you watered him, my son," my father said. I looked at Maria and she was lovely. She was tall. Beside my brother Leon, she was tall and very still. Then I went out, and in the darkened hall the fragrance of her was like a morning when papayas are in bloom.
Back to topBack to Philippine Literature in English
Posted by acas arnel m. at 4:22 AM
Labels: Short story
Functions
0 commentsCS Code Segment 16-bit number that points to the active code-segment
DS Data Segment 16-bit number that points to the active data-segment
SS Stack Segment 16-bit number that points to the active stack-segment
ES Extra Segment 16-bit number that points to the active extra-segment
Pointer Registers
IP Instruction Pointer 16-bit number that points to the offset of the next instruction
SP Stack Pointer 16-bit number that points to the offset that the stack is using
BP Base Pointer used to pass data to and from the stack
General-Purpose Registers
AX Accumulator Register mostly used for calculations and for input/output
BX Base Register Only register that can be used as an index
CX Count Register register used for the loop instruction
DX Data Register input/output and used by multiply and divide
Index Registers
SI Source Index used by string operations as source
DI Destination Index used by string operations as destination
Flags Register Abr. Name bit nº Description
OF Overflow Flag 11 indicates an overflow when set
DF Direction Flag 10 used for string operations to check direction
IF Interrupt Flag 9 if set, interrupt are enabled, else disabled
TF Trap Flag 8 if set, CPU can work in single step mode
SF Sign Flag 7 if set, resulting number of calculation is negative
ZF Zero Flag 6 if set, resulting number of calculation is zero
AF Auxiliary Carry 4 some sort of second carry flag
PF Parity Flag 2 indicates even or odd parity
CF Carry Flag 0 contains the left-most bit after calculations
Posted by acas arnel m. at 9:21 PM
Labels: Assembly Codes
Input Output
1 commentsmodel small
.stack 100h
.data
msg db "enter ur choice: [1-5]$"
una db "one$"
duha db "two$"
tulo db "three$"
upat db "four$"
lima db "five$"
pawala db "error input$"
.code
start:
mov ax,@data
mov ds,ax
mov dx,offset msg
mov ah,09h
int 21h
;input
mov ah, 01h
int 21h
mov dl,al
;enter
xor ah,ah
int 16h
cmp dl, '1'
je one
cmp dl, '2'
je two
cmp dl, '3'
je three
cmp dl, '4'
je four
cmp dl, '5'
je five
jne exit
one:
mov dx, offset una
mov ah, 09h
int 21h
je human
two:
mov dx, offset duha
mov ah, 09h
int 21h
je human
three:
mov dx, offset tulo
mov ah, 09h
int 21h
je human
four:
mov dx, offset upat
mov ah, 09h
int 21h
je human
five:
mov dx, offset lima
mov ah, 09h
int 21h
je human
exit:
mov dx, offset pawala
mov ah, 09h
int 21h
je human
human:
mov ax, 4c00h
int 21h
end start
Posted by acas arnel m. at 9:16 PM
Labels: Assembly Codes