Fundamentals of Programming Lecture 1 Agenda



Download 379 Kb.
Sana10.09.2021
Hajmi379 Kb.
#170457
Bog'liq
lecture1 (1)

Fundamentals of Programming

  • Lecture 1

Agenda

  • What the module is all about.
  • Assessment.
  • What is programming?
  • What is hardware, an operating system, software?
  • What is a computer language?

What the module is all about.

  • By the end of the module you should be able to write reasonably sized VB.NET programs
  • You should have a solid basis of how programming works (Principles)
  • The latter will allow you to explore VB.NET yourself in greater details, or EVEN to learn a new language independently!

About The Module

  • Assignments
    • Practical tests (computer-lab)
      • Test I – general programming problems
      • Test II – db access
  • Tutor
    • Vasiliy Kuznetsov
  • Senior Lecturer
  • Westminster International University in Tashkent

What is a Computer?

  • Computers can handle repetitive chores without becoming bored or exhausted.
  • A computer is programmable to handle different tasks:
    • Financial calculations
    • Processing words
    • Playing games
  • Computer actions are composed of huge numbers of extremely primitive operations
  • The computer gives the illusion of smooth interaction because it executes these operations with a great speed.
  • Computers are flexible: they can handle a wide range of tasks.

What is Programming?

  • A program tells the computer the sequence of steps needed to fulfill a task.
  • A programmer designs and implements these programs.
  • Most computer users are not computer programmers.
  • Programming is an essential skill for a computer scientist.

What is a Computer Language?

  • A special language that allows people to communicate with computers
  • Modern computer languages use words from human languages, have rules of grammar, syntax and punctuation
  • In general, programming language is a way to say to a computer what to do

The Anatomy of a Computer (CPU, Memory, and bus)

  • CPU (Central Processing Unit):
    • Plastic, metal and mostly silicon.
    • Composed of several million transistors.
    • Enormously complicated wiring.
    • Performs program control, arithmetic, and data movement.
    • Locates and executes program instructions.
  • Memory:
    • RAM (Random Access Memory): read-write memory.
    • ROM (Read Only Memory): contains certain programs that must always be present.
  • Secondary storage
    • (e.g. a hard drive) provides persistent storage.
  • Bus
    • is a set of electrical lines that connect the CPU, RAM, and other devices.

The Anatomy of a Computer

Programming languages: 1st Generation

  • Machine instructions:
    • Extremely primitive
    • Encoded as numbers:
  • 161 40000 45 100 127 11280
  • Tedious and error prone to look up numeric codes and enter them manually.
  • Each processor has its own set of machine instructions.

Programming languages: 2nd Generation

  • Assembler
    • One-to-one correspondence with instructions
    • Assigns short names to commands:
  • mov 40000, %eax
  • sub 100, %eax
  • Makes reading easier for humans
  • Translated into machine instructions by another program
  • Still processor dependent

Programming languages: 3rd Generation

  • Higher-level languages:
    • Independent of the underlying hardware
    • Easiest for humans to read and write
  • if (int_rate > 100)
    • MessageBox("Interest rate error");
  • Translated by compilers into machine instructions

Programming languages: 4th Generation

  • Indicates “What to do” rather then “How to do that”
    • Select * From tb_users
  • SQL, Report generators

Compiled languages vs. Interpreted

  • Compiler converts source code into machine-specific instructions BEFORE execution (at compile time)
    • Faster execution
    • Need to recompile to make changes
    • C++, .Net, Java
  • Interpreter converts source code into processor-specific instructions DURING the execution (run-time, just-in-time)
    • Slower execution
    • Allows to change code at run-time
    • PHP, JavaScript
  • The Compilation Process (Diagram)

The Compilation Process (Definitions)

  • You write source code - that is your program
  • The compiler is a program that translate your source code into object code
  • Object code consists of machine instructions and information on how to load the program into memory
  • A linker program takes the object code from your program and the code from the various libraries and builds them into an executable file
  • Libraries contain the (already translated) code used by your program (such as System.Data)

The need to abstract the operating system

  • Platform dependency
  • Solution – another abstraction layer
  • Java VM, .NET Framework (Mono project)

.Net Compilation (schematic)

  • Run Time
  • Source Code
  • Microsoft Intermediate Language
  • CLR just in-time compiler
  • Native code
  • The End

Download 379 Kb.

Do'stlaringiz bilan baham:




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish