Archive for Class Blog (MAIN)

Ruby Questions

1.What is a variable?

A variable is save a thing and give it a name. You used the equals sign to do this.
it is like a ticket not a ticket!

2.What is a method?

Methods are an action e.g .reverse

3.What is an array?

Array are lists for storing things in order

4.What is the difference between ticket.sort and ticket.sort! ?

Ticket saves the msg or string, and ticket sort! is to put the letters or frases into order e.g   

5.Identify 3 Ruby methods and explain their purpose.

Reverse= give a name or word its backward state example “Liam”, “maiL”

.to_s.reverse= to make a number back to front u cant just put 40.reverse & also these

 

  • to_s converts things to strings.
  • to_i converts things to integers (numbers.)
  • to_a converts things to arrays
  • [12, 47, 35].max= Sorts throught the numbers to give u the highest.

    A LITTLE TOCH OF RUBY!

    When i was on ruby i found it very simple to use yet i did get cought afew times with typeing in the wrong letters, symbols, or…my spelling was just plain wrong….

    All in all it was a well spent 15+ MINUTES spent i have some interesting pictures of some of the things i was told to do.

     Figure 1

    Ruby 2

     

    Teacher contact codes and friends!

    Binary and Hexadecimal Conversions

     

    Binary Code

    64

    32

    16

    8

    4

    2

    1

    Decimal Number

    a

    0001011

    0

    0

    0

    1

    0

    1

    1

    11

    b

    1000000

    1

    0

    0

    0

    0

    0

    0

    64

    c

    1010111

    1

    0

    1

    0

    1

    1

    1

    87

    d

    1001001

    1

    0

    0

    1

    0

    0

    1

    73

    e

    1100001

    1

    1

    0

    0

    0

    0

    1

    97

    f

    0011111

    0

    0

    1

    1

    1

    1

    1

    31

    g

    1110001

    1

    1

    1

    0

    0

    0

    1

    113

    h

    1111101

    1

    1

    1

    1

    1

    0

    1

    121

    i

    1000010

    1

    0

    0

    0

    0

    1

    0

    66

    j

    1111111

    1

    1

    1

    1

    1

    1

    1

    127

     

     

     

     

     

     

     

     

     

     

     

    Decimal number

    64

    32

    16

    8

    4

    2

    1

    Binary Code

    a

    65

    1

    0

    0

    0

    0

    0

    1

    1000001

    b

    19

    0

    0

    1

    0

    0

    1

    1

    0010011

    c

    40

    0

    1

    0

    1

    0

    0

    0

    0101000

    d

    47

    0

    1

    0

    1

    1

    1

    1

    0101111

    e

    101

    1

    1

    0

    0

    1

    0

    1

    1100101

    f

    78

    1

    0

    0

    1

    1

    1

    0

    1001110

    g

    119

    1

    1

    1

    0

    1

    1

    1

    1110111

    h

    58

    0

    1

    1

    1

    0

    1

    0

    0111010

    i

    98

    1

    1

    0

    0

    0

    1

    0

    1100010

    j

    124

    1

    1

    1

    1

    1

    0

    0

    1111100

     

     

    Hexadecimal

    4096

    256

    16

    1

    Decimal Number

    a

    1D

     

     

    1

    D

    29

    b

    13

     

     

    1

    3

    19

    c

    18

     

     

    1

    8

    24

    d

    130

     

    1

    3

    0

    304

    e

    274

     

    2

    7

    4

    628

    f

    142

     

    1

    4

    2

    322

    g

    34A

     

    3

    4

    A

    843

    h

    2A21

    2

    A

    2

    1

    11041

    i

    FF

     

     

    F

    F

    272

    j

    10DE

    1

    0

    D

    E

    4335

     

     

     

     

     

     

     

     

    Decimal Number

    4096

    256

    16

    1

    Hexadecimal

    a

    600

     

    2

    5

    8

    258

    b

    21

     

     

    F

    5

    F5

    c

    40

     

     

    2

    8

    28

    d

    42

     

     

    2

    A

    2A

    e

    258

     

    1

    0

    2

    102

    f

    342

     

    1

    5

    6

    156

    g

    612

     

    2

    6

    4

    264

    h

    4096

    1

    0

    0

    0

    1000

    i

    4134

    1

    0

    2

    6

    1026

    j

    1000

     

    3

    E

    8

    3E8

    Paint vs Adobe Photoshop

    Paint:

    Paint is a basic art program it is used for making symbols, banners or pixle art…if you have alittle skill it can be very helpful with anything you have to do. Best of all its free, Paint comes with any Windows program, always has. Paint is also Oh so very simple to use, it is extreamly self explanitory and its program can be used to convert any file into another. For example, if you have a bmp image and you wont to post it to the net but they only accept GIF then you can go to paint import it into the plank page and then save it as a GIF file (how useful =[) ). Yet paint does have its "draw" backs, it has a problem with minamizing and maximizing images. Unlike microsoft windows word it is not mathamaticle. This means that when you make any image larger in paint it becomes very pixlized, (how ugly =(] ). Yet in microsoft word you can make ur image lager and smaller with no loss of data at all. One other issue faced by Paint is that when you convert a file to another example bmp to JPEG you can lossed soem colour. Now this does not mean that ur person u drew with a lovely red jumper will now have a green one when u save it as a JEPEG file no. This means that afue extra pixles will be added, making it hard to eddit ur image.

    Adobe photo shop:

    Adobe photo shop is a make more sefisticated version of paint, in this i mean that it has extra features for example, it is much smarter it can recognize colours and shapes. You can use a wond to cut out say a car from a background. Adobe has been given a little logo. When you see a car that looks fantastic or see a modle that doesnt look real, either you will say or you will hear it said “Photo shop” or “air brush”. Air brush is a very usful tool that uses the same technique as the wond to erase particulare shapes and colours from the image….example skin blemishes. (yes air brush can also mean a real “air brush”, but thats not what im talking about. Paint shop pro unlike Paint can minimize any images and re-scale it without loss of info, yes it uses math aswell. Yet with its formats it is not so simple there is only 3 choices to choose from, JAPEG, JPEG, GIF. But no loss or adding of pixles.

    Conclution:

    Well speaking from a profetionals veiw yes Adobe photoshop is better for a better finish. Yet if your alittle slow and like things to be simple then Paint is the way to go. Using paint does not mean you will end up with a horrid picture, just simply means it wont be the best.

    Generation Programming languages

    001001001110101101010011011101110101011101010100011010100101010101010101110

    What is its purpose?

    It allows a user to write a stemp by step program that tells a computer how to carry out a task.

    Generation 1

    Code is usable by only one type of processor.

    Generation 2

    Use shortened instructions called mnemonics that are more easily understood by the user

    Generation 3

    Code is written as instructions detailing how a task is to be done

    Generation 4

    Most are non-procedural languaged where users define only what they want they computer to do.

    Generation 5

    Advanced types of 4GLs

    10101010001010111010101010101110101000101010101011011010101001011010010101101

     

     

    Examples

    Wordprossesor:

    Microsoft word

    Publisher

    Wordpad

    Blog

    WordPress

    Animalcrossing Comunity

    Myspace

    Game

    Gamemaker

    Scratch

    Pivot

    Art

    Adobe Photoshop

    Jasc Paintshop

    Paint

    Graphic Designor

    ProDESKTOP

    Sketchup

    GameMaker

    Parts of a computer

    General Parts of a computer:

    1) Software

    2) Hardware

    3)Prossesors

    4) Data

    5) Opporator

    SOFTWARE

    SOFTWARE

     

                   System

                                                                                                                       Application

                                                     Utilities

                                                     E.g. Divers/antivirus/ect….

                       Os

                                                                                                  Custom            off the shelf  

     

     

    CLI           GUI            NGI

     

                                                                          Natural Language Interface

     

     

     

    Command Line Interfere e.g. DOS UNIX

    The above is a table of what we did in class just emagin it with lines =[)

    In this table we find many system softwares, one that i found interesting was DOS i have seen it in the past yet never knw what it was or even if it was a system.

    Off the shelf systems and on the shelf systems (Custom) Are easy to find. Yet it is not simple to determain what a typical off the shelf or custom would be. For e.g Norton is usualy a custom yet u can save money by buying it off the shelf.

    Wiki space

    finished-fec.gif

    « Previous entries
    Follow

    Get every new post delivered to your Inbox.