In this task, the job is to verify that a file called "input.txt" and the directory called "docs" exist. This should be done twice: once for the curre
Continue ReadingC++: Delegates
A delegate is a helper object used by another object. The delegator may send the delegate certain messages, and provide a default implementation when
Continue ReadingC++: Empty String
Languages may have features for dealing specifically with empty strings (those containing no characters). The task is to: Demonstrate how to a
Continue ReadingC++: Enforced Immutability
Demonstrate any means your language has to prevent the modification of values, or to create objects that cannot be modified after they have been creat
Continue ReadingC++: Fibonacci Sequence
The Fibonacci sequence is a sequence Fn of natural numbers defined recursively: F0 = 0 F1 = 1 Fn = Fn-1 + Fn-2, if n>1 Write a function to ge
Continue ReadingC++: Hailstone Sequence
The Hailstone sequence of numbers can be generated from a starting positive integer, n by: If n is 1 then the sequence ends. If n is even then
Continue ReadingC++: IBAN
The International Bank Account Number (IBAN) is an internationally agreed means of identifying bank accounts across national borders with a reduced ri
Continue ReadingC++: Ackermann Function
The Ackermann function is a classic example of a recursive function, notable especially because it is not a primitive recursive function. It grows ver
Continue ReadingC++: Deal Cards for FreeCell
Free Cell is the solitaire card game that Paul Alfille introduced to the PLATO system in 1978. Jim Horne, at Microsoft, changed the name to FreeCell a
Continue ReadingC++: Evolutionary Algorithm
Starting with: The target string: "METHINKS IT IS LIKE A WEASEL". An array of random characters chosen from the set of upper-case letters toge
Continue Reading




