Wednesday, March 28, 2012

11 ශ්‍රේණිය තොරුතුරු පද්ධති 

පද්ධතියක් යනු කුමක්ද
මනුෂ්‍ය ශරීරය , ‍රෝහල , පාඨශාලාව , කර්මාන්ත ශාලාව ආදී ඕනෑම ආයතනයක් තුළ පහත පොදු ලක්ෂණ දැකිය හැකිය.
       අනු කොටස් (සංඝටක) කිහිපයක් තිබේ.
       ඒවා එකිනෙක සම්බන්ධිතය
       ඒවා වෙන වෙනම මෙන්ම එක්ව ද ක්‍රියා කරයි
       එම කොටස් යම් අරමුණක් සපුරා ගැනීම සඳහා   කටයුතු කරයි
       එම අනු කොටස් උප පද්ධති ලෙස ක්‍රියා කරයි
එබැවින් ඉහත ලක්ෂණ වලින් සමන්විත ඒකකයක් පද්ධතියක් ලෙස හැඳින්විය හැකිය.
පද්ධතියක ප්‍රධාන ක්‍රියාවලි මොනවාද
පද්ධතියක් ප‍්‍රධාන වශයෙන් කි‍්‍රයාවලි 3 කින් සමන්විත වේ.
1.       ආදානය 2. සැකසුම 3. ප‍්‍රතිදානය
අභ්‍යාසය
        I.            පාසල ,රෝහල , පරිගණකය යනු පද්ධති 03 කි. ඒවායේ ආදානයන් සැකසුම් හා ප්‍රතිදානයන් ලියන්න.
      II.            දත්ත තොරතුරු බවට හැරවීම සඳහා පරිගණක පද්ධතියක් තුළ අනිවාර්යයෙන්ම තිබිය යුතු සංඝටක 03 ක් ලියන්න.
තොරතුරු පද්ධති යනු මොනවාද ?
       ආයතනයක හෝ ව්‍යාපාරයක එදිනෙදා කටයුතු සාර්ථක ව සිදු කිරීම සඳහා නිවැරදි තොරතුරු ඉතා වැදගත්
       එම තොරතුරු නිෂ්පාදනය කිරීමට යොදා ගන්නා පද්ධතිය තොරතුරු පද්ධතියකි.
තොරතුරු පද්ධතියක අඩංගු දෑ මොනවාද ?
      පුද්ගලයන්,
      දත්ත,
      ජාල,
      උපකරණ,
      තාක්ෂණය
තොරතුරු පද්ධති වර්ගීකරණය
       අතින් සිදු කරන (හස්තීය ) පද්ධති
      මෙවැනි පද්ධතිවල දී සියලූ ම සැකසුම් පුද්ගලයන් විසින් අතින් සිදු කරනු ලැබේ.
      සියලූ ම ගණනය කිරීම් ද අතින් සිදු කළ යුතු අතර කඩදාසිවල ලියා ලිපි කවර තුළ හා සේප්පු තුළ ලිපි ගොණු වශයෙන් දත්ත හා තොරතුරු තබා ගත යුතු ය
       පරිගණක මත පදනම් වූ තොරතුරු පද්ධති
අභ්‍යාසය
        I.            අතින් සිදු කරන (හස්තීය ) තොරතුරු පද්ධතියක අවාසි මොනවාද
      II.            පරිගණක මත පදනම් වූ තොරතුරු පද්ධතියක ඇති වාසි මොනවාද
    III.            පරිගණක මත පදනම් වූ තොරතුරු පද්ධතිය ක සංඝටක මොනවාද ?
තොරතුරු පද්ධති වර්ග
 යම් ආයතනයක ‍පුද්ගල සම්පත ඔවුන් හට පැවරී ඇති රාජකාරි අනුව කාණ්ඩ වලට වෙන් කළ හැකිය. ( ලිපිකරුවන් , ගබඩා පාලකයින් ,කළමණාකරුවන්, අධ්‍යක්ෂ මණ්ඩල ) එවැනි එක් එක් කාණ්ඩය අනුව ඔවුන් ට අවශ්‍ය තොරතුරු එකිනෙකට වෙනස් වේ. එනිසා එවැනි තොරතුරු නිර්මාණය කිරීම සඳහා යොදා ගන්නා තොරතුරු පද්ධති වර්ගීකරණය කළ හැක.            
       ගනුදෙනු සැකසුම් පද්ධති (Transaction Processing systems)
        පරිපාලන තොරතුරු පද්ධති(Management Information systems)
        තීරණ සහයෝගී පද්ධති (Decision support systems )
        විශේෂඥ පද්ධති (Expert Information system)
අභ්‍යාසය
ඔබේ පෙළ පොත අනුව  ඉහත එක් එක් පද්ධති වර්ගය හඳන්වන්න
තොරතුරු පද්ධතියක් සැකසීම අනුගමනය කරන චක්‍රාකාර ක්‍රියාවලිය 
System development Life Cycle(SDLC)
යම් ආයතනයක ක්‍රියාවලිය සදහා  හෝ පරිශීලක අවශ්‍යතා සදහා  තොරතුරු පද්ධතියක් සැකසීම විද්‍යානුකූල ක්‍රමවේදයක් අනුව සිදු කරනු ලැබේ. සාමාන්‍යයෙන් මෙහිදී පහත පියවර අනුගමනය කරන අතර එහි පළමු පිවයර 04 පද්ධති විශ්ලේශක (system analyst) විසින් සිදු කරයි. කේත ලිවීම හා පරීක්ෂා කිරීම පරිගණක ක්‍රමලේඛණ ශිල්පීන් (Computer programmers) ගේ කාර්යයන් වේ‍.

       ගැ‍ටඵව හදුනා ගැනීම (Identification of the problem) 
       ශක්‍යතා අධ්‍යයනය (Feasibility study)
       පද්ධති විශ්ලේෂණය (System Analysis)
       පද්ධතිය සැළසුම් කිරීම (System design)
       පද්ධතිය සැකසීම සදහා  කේත  ලිවීම (Coding)
       සැකසූ පද්ධති‍‍යේ ක්‍රියාකාරිත්වය පරීක්ෂා කිරීම හා දෝෂ නිවැරදි  කිරීම  (Testing & Debugging)
       පද්ධතිය භාවිතාවේ යෙදවීම (Implementation)
       පද්ධතිය නඩත්තු තිරීම  (Maintenance)
ගැ‍ටඵව හදුනා ගැනීම (Identification of the problem) 
යම් ආයතනයකට තොරතුරු උත්පාදනය කර ගැනීම සදහා පහසු ක්‍රමවේදයක් අවශ්‍යවේ නම් එම ආයතනය සදහා තොරතුරු පද්ධතියක් සැකසිය හැකිය. මෙම අවශ්‍යතාවය මෙහිදී ගැටඵව ලෙස සලකනු ලබයි. එම ගැටඵව ඇති සැටියෙන්ම හදුනා ගැනීම සදහා පහත කරුණු කෙරෙහි අවධානය යොමු කිරීම වැදගත් වේ.
1)පද්ධතිය තුලින් බලාපොරොත්තුවන ප්‍රතිදානයන්/ පරිශීලක අවශ්‍යතා (Output)
2) පද්ධතියට ඇතුඵ කිරිම‍ට සිදුවන දත්ත (input)
3)පද්ධතියේ විෂය සීමාවන්/වපසරිය (Scope)
4)පද්ධතියේ පරිශීලකයන් කවුරුන්ද යන කාරණය සහ ඔවුන්‍ට අවශ්‍ය අදාන ප්‍රතිදාන අතුරුමුහුණත්
පද්ධති විශ්ලේෂණය
‍1) දැන‍ට ක්‍රියාත්මකවන පද්ධතිය පිළිබද දීර්ඝ හා අංගසම්පූර්ණ ලෙස හැදෑරීම
2) අඵතින් ‍ගොඩනැංවිය යුතු පද්ධතියේ තිබිය යුතු මෙහෙයුම්  අවශ්‍යත‍ා
3)පද්ධතිය හා බාහිර ලෝකය අතර තිබිය යුතු සබදතා
4) ගොඩනැංවීමට ‍බලාපොරොත්තුවන නව පද්ධතියේ පිරිවිතර පිළිබද සම්පුර්ණ වාර්තාවක්
5) අධ්‍යයනය සදහා දත්ත එක් රැස් කිරීම
            දත්ත/තොරතුරු එක් රැස් කිරීමේ ක්‍රම
            සම්මුඛ සාකච්ඡා / පුශ්නාවලි /ලේඛන පරීක්ෂාව / නිරීක්ෂණ /කණ්ඩායම් සාකච්ඡා
තොරතුරු පද්ධති ප්‍රශ්න මාලාව - 01 -ප්‍රශ්න සියල්ලටම පිළිතුරු සපයන්න
1) තොරතුරු පද්ධති වර්ග 2 කින් එකක් වනුයේ අතින් සිදු කරන තොරතුරු පද්ධතිය. එසේ නම් අනෙක් වර්ගය  නම් කරන්න.
2) සේවකයින් 150 ක් සිටින කර්මාන්ත ශාලාවක වැටුප් සකස් කරනු ලබන්නේ වැටුප් ලිපිකරුවන් විසිනි. පරිගණක ගත තොරතුරු පද්ධතියක් යොදා නොගැනීම හේතුවෙන් ඇතිවිය හැකි අවාසි 03 ක් සදහන් කරන්න.
3) යම් ආයතනයකට තොරතුරු පද්ධතියක් සැකසීමේ දී එහි දැන් පවත්නා පද්ධතියේ සේවකයින්ට ලබාදෙන ප්‍රශ්නාවලි මගින් තොරතුරු එක් රැස් කරයි . මෙසේ ‍කරනු ලබන්නේ පද්ධති සං‍වර්ධන චක්‍රයේ කුමන පියවරේදීද
4) තොරතුරු පද්ධති වලි ක්‍රියාකාරිත්වයන් අනුව ‍ඒවා වර්ගීකරණය කරන්න.
5) දැනට සිටින සේවක සංඛ්‍යාව යොදා ගනිමින්  මාසයක කාලයක් ඇතුලත ඇගලුම් තොගයක් සැපයීම ලාභ දායක වන්නේද නොවන්නේද යන්න විමසා බැලීමට ඇගලුම් කම්හල් අයිතිකරුවෙකුට අවශ්‍යවේ. මේ සදහා යොදා ගත හැකි තොරතුරු පද්ධතිය කුමන වර්ගයකට අයත් වේද ? මෙවැනි පද්ධතියක් උපයෝගී කර ගැනීමට සිදුවන්නේ ගබඩා භාරකරු සහ කළමණාකරු යන දෙදෙනා අතුරින් කාහටද?
6) පද්ධතියක් නිර්මාණය කිරීමට පෙර ඒතුළ තිබිය යුතු අවශ්‍යතා වර්ග 2 වෙන වෙනම විමසා බලයි. මෙම අවශ්‍යතා වර්ග 2 කෙටියෙන් පහදන්න
7) පද්ධති සැලසුම් කිරීමේ දී අනුගමනය කරන ප්‍රධාන කාර්යයන් 2 ක් නම් කර ඒවා කෙටියෙන් විස්තර කරන්න.
8) පද්ධතියක් ගොඩනැගීම සදහා ක්‍රමලේඛන භාෂාවකින් ක්‍රමලේඛනය කිරීම කේතනය ලෙසින් හැදින්වේ. මෙම පියවරේදී සිදු කරන කාර්ය‍ය කෙටියෙන් පහදන්න.

sarathBo@Gmail.com-0716537411

Thursday, March 22, 2012


AL ICT Competency 07 - LAB sheet for Python Language --sarath Bogahapitiya/07165374111
1.       Write a program to output a text message. Save the file as “Output.py” (use print command)
2.       Write a program to input some text , sore it in a variable and output that text. Save it as “input_output.py”.{Use raw_input(“Enter some text”) command to input the text}
3.       Write down the difference of output of these between these two lines.
a.       thetext = raw_input("Enter some text ")
b.      thetext = raw_input("Enter some text \n")
4.  Type the following program and save it as “input_output2.py”. Run the program.
prompt  = "Enter  some text "
thetext = raw_input(prompt)
print "This is what you entered:"
print thetext
5.   Type the following a  and b commands in python shell. What is the difference of a and b. State the reason for the difference.
a.  >>> number1= raw_input("Enter the first number: “)
>>> print number1

b. >>>number1= float(raw_input("Enter the first number: “)
>>>print number1
                
6.  >>>number1= float(raw_input("Enter the first number: “)
>>> print “The number you entered is” +number1
You will get an error  when executing the two lines above. Describe why  ? After running the above two command Change the second line to remove the error.

7.       number1 = raw_input("Enter first number:\n") what will be the data type of number1 ? check your answer ?
8.       Write a python program to calculate the total and average of any user input 3 numbers. The program should display the total and the average like this.
The total is 56.98
The average is 25
9.       Total and count are two variables. Write a program and initialize them to 0. When you run your program the user should enter 3 numbers.  Write  a  program  calculate the total and the average for  user input 3 numbers. The program should do using the while keyword. (while loop).

10.    Here you get mixing data types in expressions . Mixed type expressions are "converted up"  converted up means to take the data type with the greater storage  float has greater storage (8 bytes) than a regular int (4 bytes) write down the result after execute the code

a.       print 2 + 4
b.      print 2 + 4.0
c.       print 6 - 4.0
d.      print 6 * 3.0
e.      print 6 / 3
f.        print 6 / 3.0
g.       print 6 % 3.0
h.      print 6 // 3.0 # floor division: always truncates fractional remainders
i.         print -5.0
j.        print 3**2
k.       print 3**2.0  
   
11.   these are string objects Write down the result after execute the code.
print "Hello out there"
print 'Hello'
print "Where's the spam?"
print 'x'
12.   Type the following program and write the result. Examine the code and point out the error before you run it.   If there is an error in the code then comment it and run the program again.
a = 'Hello students'
b = "how is programming?"
c = a + b
print c
d = c + 10
d = c + str(10)
print d
13.In this program you will see how type conversion has done.
a = "10"
b = '99'
c = a + b
i)        Write the command to Print the value of c
ii)       Check the data type of c
iii)     How can you convert the data type of c to integer and assign tits  value to c

14.    If x= 6.3 ,how you can round this floating point number and convert to the nearest integer.
15.      Here you get  Boolean expressions which result in a value of  true or false. ( Note that Python stores true as integer 1, and false as integer 0  but outputs 'true' or 'false' from print statements)

print 7 > 10
print 4 < 16
print 4 == 4
print 4 <= 4
print 4 >= 4
print 4 != 4
print 4 <> 4

AL ICT - programming language – Python -Assignment 1


AL ICT - programming language – Python -Assignment 1
11)     What do the follow Python statements return? If an error results, just write "error". (assume that you be the interpreter)

                 What You Type

                What Python Returns


>>> 1 + 2 * 3

>>> 4 ** (5 - 2 - 1)

>>> len('cat') + 2 * len('mouse')

>>> len(str(2 * 3 * 4))

>>> int(3 * str(2))

>>> 4 * "10"

>>> "4" * "10"

    2 )    You must use exact Python syntax in the following questions!!
Question                                                                Answer
 Write a fragment of Python code that works as follows. Ask the user to enter their favourite drink, and if they say "water", print "good!". Otherwise, print "what a poor idea".



Write a for-loop that prints the numbers 1000 down to 1 (inclusive), one number per line, i.e.:

 1000
 999
 998
 .
 .
 .
 2
 1

 Re-do the previous question, but this time use a while-loop.


33)How old is Python? What languages does it relate to? Give a very brief summary about python language.

4 4) Consider the following Python fragment:

     n = 3
     m = 5
     n = n + m
     m = n – m
     n = n – m
What values do we have in the two variables at the end? Can you summarize the meaning of the last three lines, in general?
5.     Consider the following code:
if x > 3:
  if x <= 5:
    y = 1
  elif x != 6: 
    y = 2
  else:
    y = 3
else:
  y = 4

If y has the value 2 after executing the above program fragment, then what do you know about the initial value of x?
 6)   Consider the following two fragments:

if x == 5:
  x = x + 1
else: 
  x = 8
if x == 5:
  x = x + 1
if x != 5:
  x = 8

Are the two fragments logically equivalent? Why or why not?
  
7) Simplify the following expressions:  assume that a=5
·         a and not a  …………………………………
·         a or not a   …………………………………
·         x >= 6 and x < 7  …………………………………
·         a == False …………………………………
·         a == True  …………………………………
·         a or True  …………………………………
·         a and True  …………………………………
·         a and False  …………………………………
·         a or False  …………………………………
·         False and False or True  …………………………………
·         False and (False or True)  …………………………………

        8)   What is the output  of the following code fragment:
      n = 10
     m = n
n = 12
print m
Does the change in n affect m at all? Why (or why not)?
  
9) Briefly explain and evaluate (assume i holds an integer value):
i = i + 1
i == i + 1
i == i
i = i
10.                        Consider the following Python code:
i = 10
while i < 10:
    i = i - 1
print i
What does it print (or amount to)? Do you see any potential problem with it
11.        s = 0
i = 10
while i > 0:
    s = s + i
    i = i - 1
print s
What does it print (if anything)?

12.                          Your school wants you to write a program for them that will calculate the average number of wins for their chess team over the past five years.  The user of the program should be able to enter the number of wins each year.  The program will calculate the average number of wins during that five year period and display that information to the screen.  Draw a flowchart and write a python program to accomplish the above task.

13.                        A dietician wants you to write a program that will calculate the number of calories a person can lose by walking at a slow pace for a mile; however, the user will have only the distance given by a pedometer, which is measured in steps and not miles.  Assume each mile a person walks is equivalent to 2000 steps, and that for every mile walked, a person loses 65 calories.  Allow the user of the program to enter the number of steps taken throughout the day.  The program will calculate the distance in miles and the number of calories lost.  The user of the program should also be able to enter the day of the week the data is being calculated for.  The day of the week, the distance in miles, and the calories lost should then be displayed to the screen. The algorithm is given for you
a.       Get the day of the week.
b.      Get the number of steps reported on the pedometer.
c.       Divide the number of steps taken by 2000, which is the number of steps per mile.
d.      Multiply the result of Step 3 times 65, which is the number of calories burned per mile.
e.      Display the input information in Step 1.
f.        Display the calculated information in Step 4 and 5.
Draw a flow chart and write a python program to accomplish the task/
14.                        Is the loop in the code below infinite? How do you know (for sure) before you run it?
m = 3
n = 5
while n < 10:
    m = n - 1
    n = 2 * n - m
    print n, m
15.                        Test the given 2 examples to practice for loop and write down the output of each.
for letter in 'Python':     # First Example
   print 'Current Letter :', letter


fruits = ['banana', 'apple',  'mango']
for fruit in fruits:        # Second Example
   print 'Current fruit :', fruit

print "Good bye!"

16.                        Test the given 2 examples to practice while loop and write down the output of each.
count = 0
while (count < 9):
   print 'The count is:', count
   count = count + 1

print "Good bye!"

17.                        Write the  output of the following program before you run it. Then check your answer with running the program.
for letter in 'Python':    
   if letter == 'h':
      break
   print 'Current Letter :', letter
 
18.                        Write the  output of the following program before you run it. Then check your answer with running the program.

var = 10                   
while var > 0:             
   print 'Current variable value :', var
   var = var -1
   if var == 5:
      break
19.                        Write the  output of the following program before you run it. Then check your answer with running the program.
for letter in 'Python':    
   if letter == 'h':
      continue
   print 'Current Letter :', letter
20.                        Write the  output of the following program before you run it. Then check your answer with running the program.
var = 10                    
while var > 0:             
   var = var -1
   if var == 5:
      continue
   print 'Current variable value :', var
print "Good bye!"



Memory Locatıons and Addresses (Week 3) - ppt download

Memory Locatıons and Addresses (Week 3) - ppt download : Memory Locations and addresses We will first consider how the memory of a computer...

Total Pageviews

Followers