how i exercise bit map?


i wish exercise 2d bit map category python. category have following requirements:




  1. allow formulating arbitrarily sized 2d bitmaps. i.e. emanate an 8 x 8 bitmap (8 bytes), something like:



    bitmap = bitmap(8,8)

  2. provide an api opening pieces 2d map boolean even integer values, i.e.:



    if bitmap[1, 2] bitmap.get(0, 1)

  3. able collect information packaged binary data. radically any quarrel bit map concatenated returned binary data. competence padded nearest byte something similar.



    bitmap.data()

  4. be means emanate new maps binary information retrieved:



    new_bitmap = bitmap(8, 8, bitmap.data())



i know python means perform binary operations, nonetheless i'd suggestions best exercise class.



Comments

Popular posts from this blog

why does floated <input> control floated component slip over too distant right ie7, nonetheless firefox?

grails record upload problems

how i emanate permitted url asp.net mvc?