John McSweeney

  • Home
  • Archives

July 1, 2025

FAQ

 

This represents a list of questions that some students have asked. Hopefully the answers will help others.

  1. Can you explain the difference between affordance and visibility?
  2. Is there a difference between a message answer and the textual representation of a message answer?
  3. Could you explain to me the concept of classes as instances of metaclasses?
  4. Why does 3.1 == 3.1 return false?
  5. Are floats immutable?
  6. Should we use ByteString or TwoByteString?
  7. Is it possible to reset the attributes of an initialised object to different types of objects?
  8. What is the difference between an instance method and a class method?
  9. I would like to know why we have a string literal defined as '123' and a number literal defined as 123? Why have two different ways to define an object and how would we use them?
  10. Can you give an example that might help me understand how to use block arguments?
  11. How do you append a character to a string?
  12. Can you give examples of Smalltalk usage and syntax?

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

⇑ Up to top of page

» OU Courses

  • M150 index
  • M206 index
  • T171 index

» Basic Smalltalk

  • What is an object?
  • Object protocol
  • Objects and encapsulation
  • Encapsulation continued
  • Abstraction
  • Reuse
  • Object attributes
  • The concept of class
  • Class hierarchy and inheritance
  • Variables
  • Messages
  • Assignment
  • Methods
  • Accessor messages
  • Guide to using accessors
  • The Artwork class
  • The protocol of Artwork and its subclasses
  • The instance methods of Artwork
  • self
  • Class methods
  • Variable-reference diagrams
  • Assignment exercise
  • Object-interaction diagrams
  • Textual representation (print-strings)
  • Precedence rules
  • The Dialog class
  • Blocks
  • Branching
  • Boolean messages
  • Conclusion

» Collections

  • Introduction
  • Set and Bag
  • Set protocol
  • Dictionary
  • Dictionary protocol
  • Array
  • Array protocol
  • Array scenario
  • String protocol
  • Symbol protocol
  • OrderedCollection
  • OrderedCollection protocol
  • The exhibition collection
  • SortedCollection
  • The retrospective collection
  • Queues
  • Queue and BuyerQueue
  • Iteration exercise

» Software Development

  • Introduction
  • Quad Gallery NSR p1
  • Quad Gallery NSR p2
  • Initial structural model
  • Deriving Classes
  • Deriving Associations
  • What not to do
  • Invariants
  • Introduction to dynamic modelling
  • Use case example
  • Conclusion
  • Class Diagram
  • Class Descriptions

» Miscellaneous

  • FAQ
  • An essay on frogs and toads.
  • Drawing with Word (Word doc 381Kb)
  • Learning Works - Hints and tips (Word doc 35Kb)
  • Basic Smalltalk (pdf 50Kb)
  • M206 Smalltalk Hierarchy Diagram (Word doc 38Kb)
  • Smalltalk Syntax
  • Smalltalk Traps and Bugs (Word doc 71Kb)

» Smalltalk Exercises

  • Textual representation and print-strings
  • Precedence
  • Boolean expressions
  • Collections - 1
  • Collections - 2

© 2025 John McSweeney |

Home |