A Simple C Program: Printing a Line of Text

C uses some notations that may appear strange to people who have not programmed computers.
I begin by considering a simple C program. First example prints a line of text. The program and its screen output are shown

1 // Fig. 2.1: fig02_01.c
2 // A first program in C.
3 #include <stdio.h>
5 // function main begins program execution
6 int main( void )
7 {
8 printf( "Welcome to Programming World!\n" );
9 } // end function main


Welcome to Programming World!

Even though this program is simple, it illustrates several important features of the C language. Lines 1 and 2

#include Preprocessor Directive Line 3 is a directive to the C preprocessor. Lines beginning with # are processed by the preprocessor before compilation. Line 3 tells the preprocessor to include the contents of the standard input/output header () in the program.

Computers Data, Control of sequences and Softwares

C is a concise yet powerful computer programming language that’s appropriate for technically oriented people with little or no programming experience and for experienced programmers to use in building substantial software systems.

you give the command to compile the program. The compiler translates the
C program into machine language-code (also referred to as object code). In a C system, preprocessor program executes automatically before the compiler’s translation phase begins.The C preprocessor obeys special commands called preprocessor directives, which indicate that certain manipulations are to be performed on the program before compilation. These manipulations usually consist of including other files in the file to be compiled and performing various text replacements.


The instructions you write to command computers to perform actions and make decisions which controls computers (often referred to as hardware). Some examples of Computer Systems i.e

Loader puts program in memory.
CPU takes each
instruction and
executes it, possibly
storing new data
values as the program

Electronic health
These might include a patient’s medical history, prescriptions, immunizations,
lab results, allergies, insurance information and more. Making
this information available to health care providers across a secure network
improves patient care, reduces the probability of error and
increases overall efficiency of the health care system.

Human Genome
The Human Genome Project was founded to identify and analyze the
20,000+ genes in human DNA. The project used computer programs
to analyze complex genetic data, determine the sequences of the billions
of chemical base pairs that make up human DNA and store the
information in databases which have been made available over the
Internet to researchers in many fields.

A billion general-purpose computers, and billions more embedded
computers are used in cell phones, smartphones, tablet computers, home appliances,
automobiles and more. Computers can perform computations and make logical decisions phenomenally faster than human beings can. Many of today’s personal computers can perform billions of calculations in one second.

Computers process data under the control of sequences of instructions called computer programs. These programs guide the computer through ordered actions specified by people called computer programmers. The programs that run on a computer are referred to as software.

How to Quit C#/CSharp application by using a line of code?

Line of Code to quit C# application

I have a few questions about C#:

You can use this method to quit. This is public static function. No need to declare any object. You just need Class name reference.

public static void Exit()





public static void Main(string[] args) {
    // Starts the application.
    Application.Run(new Form1());

 private void button1_Click(object sender, System.EventArgs e) {
    // Populates a list box with three numbers.
    int i = 3;
    for(int j=1; j<=i; j++) {

    /* Determines whether the user wants to exit the application.
     * If not, adds another number to the list box. */
    while (MessageBox.Show("Exit application?", "", MessageBoxButtons.YesNo) == 
       DialogResult.No) {
       // Increments the counter ands add the number to the list box.

    // The user wants to exit the application. Close everything down.

you can also do this.

if (System.Windows.Forms.Application.MessageLoop) 
    // WinForms app
    // Console app

Voting System

Voting System

Project: Voting System

Submitted by: Mian Raybal Akhtar




This project is about the voting system and the scenario dealing with the voting system. This project deals with how a person can vote to the candidate and how the voting system occurs. This project also keeps the record of voter like gender, voter ID, name etc and also the record of candidate.




In this class we have used the concept of inheritance as the candidate class and voter class are child classes so they can access the methods of parent class.


In this class the information about the candidate is gathered like candidate`s name, gender and the party of the candidate.


This class is used to gather the information about the voter. Voter`s name, gender and voter`s ID is entered by the user.

Voting machine

This class is used to manipulate and print the result that which is winner and how many votes he\she gained. This class has crucial role in whole system


This class uses the methods of all classes by creating their projects



First of all we will make the object of candidate class then voter class by giving the required information after then create the object of seat class.

Then we will create the object of voting machine class and will add voters and candidates after giving the information. Then after the voting is done result will be printed.



This project is about the voting it allows the voter to vote and it keeps the record of candidate and voter. Some candidates use different type of flowers and gifts near or in Election Day.





FYP Groups Details of tasks

FYP Groups and their Work Details

Group 1 (E2)

Azaz ul Haq (449-BSCS-13)                                                     03244793336

Saba Abdul Majeed (426-BSCS-13)                                         03244793337

Work Details: Full text Search Details and Query Implementation

Group 2 (E2)

Muhammad Zeeshan Amanat (455-BSCS-13)                                    03334866703

Waqar Afzal (371-BSCS-13)                                                    03014335808

Work Details: Made Slides About Entity Framework and LINQ. Integrate facebook in asp.net project

Group 3 (E2)

Mohsan Iqbal (460-BSCS-13)                                                  03124046616

Muhammad Zarif (394-BSCS-13)                                           03007514903

Work Details: Comparison

Group 4 (E1)

Group members:

Hafiza Anmol Khateeb                   (423-BSCS-13)

Asma Zafar                                         (381-BSCS-13)

Contact No:    0323-0417661

Project Title: Toolkit for Wikipedia

Group 5 (B)

Zainab Tariq (32-BSCS-13)                                                      03244766654

Noman Hafeez (26-BSCS-13)                                                  03224821903

Work Details: Mattcuts Blogs studied yet and some videos.

Group 6 (B)

Iqra Munir (05-BSCS-13)                                                         03494083211

Nazia Ramzan (87-BSCS-13)                                                   03048058484

Work Details: Difference between good relations and schemas.

Group 7 (B)

Rimsha Ayesha (14-BSCS-13)                                                  03347759465

Rubab Zahra (326-BSCS-13)                                                   03216755723

Work Details: Linq queries and Basic concept of MVC.

Group 8 (B)

Muhammad Qasim (50-BSCS-13)                                           03200440334

Khuram Saeed (311-BSCS-13)                                                 03024338806

Work Details: Difference between good relations and schemas.