Programming Languages have evolved in phases called generations. The five generations of computers are : <span>First Generation (1940-1956) Vacuum Tubes. Second Generation (1956-1963) Transistors. Third Generation (1964-1971) Integrated Circuits. Fourth Generation (1971-Present) Microprocessors. <span>Fifth Generation (Present and Beyond) Artificial Intelligence.</span></span>
The software development model that focuses on improving the product in small steps each time through the cycle is the Waterfall Process model
•
The Waterfall Process model mainly focuses on going step by step to make sure the product improves sufficiently and significantly.
•
•
- Marlon Nunez
#include<stdio.h>
#include<stdlib.h>
int comment1(FILE *fp)
{
char ch;
int count=0;
while(fscanf(fp,"%c",&ch)!=EOF)
{
if(ch=='\n')
{
return count;
}
count++;
}
return count;
}
int comment2(FILE *fp)
{
char ch;
int count=0;
while(fscanf(fp,"%c",&ch)!=EOF)
{
if(ch=='*')
{
fscanf(fp,"%c",&ch);
if(ch=='/')
{
return count;
}
count++;
}
count++;
}
return 0;
}
int main()
{
printf("Enter the file name:");
char s[1000],ch,ch1;
scanf("%s",s);
FILE*fp;
fp = fopen(s,"r");
int count=0;
while(fscanf(fp,"%c",&ch)!=EOF)
{
if(ch=='\"')
{
while(fscanf(fp,"%c",&ch)!=EOF)
{
if(ch=='\"')
{
break;
}
if(ch=='\\')
{
fscanf(fp,"%c",&ch);
}
}
}
else if(ch=='/')
{
fscanf(fp,"%c",&ch);
if(ch=='/')
{
count += comment1(fp);
}
else if(ch=='*')
{
count += comment2(fp);
}
}
}
printf("%d\n",count);
return 0;
}
Explanation:
different computer are connected to a LAN by a cable and an interface card