A new war movie based on the book “Stones for the rampart” is a story of two lads in the Polish underground movement in 1944. The film, directed by Robert Gliński, perfectly shows the social settings in Warsaw during the Second World War. The main focus is on the youth who have to live in this severe circumstances. In addition, parents of the young people and Polish society as well as German soldiers are presented.
First of all, the film is about young, well-educated, brave, decisive and companionable young people living in occupied Warsaw. Rudy is one of the main characters who speaks German fluently. Not only that, but his sister plays piano well and amuses everybody during a party at home. This clearly demonstrates a high level of education in the interwar Poland. Furthermore, the movie depicts small acts of sabotage carried out by Polish underground movement, the Gray Ranks. The young people do not hesitate if there is any occasion to weaken or lampoon the enemy. For example, they hang a German uniform filled with straw on a street lamp in the city centre. The scouts are very brave and determined to fight in any possible way. Moreover, they value their friendship very much. They rescue their friend who was interrogated and tortured by German soldiers. This is when the film reaches its climax.
On the contrary, the remaining part of the society is frightened and generally they do not want to confront the German army. Parents of the scouts want to save their lives as well as their children's lives at all costs. They try to discourage their children from fighting. Also they strive to find any source of income which is very tough during war. Most of the Polish citizens are very poor and they suffer starvation. Children kill pigeons to eat meat whereas some adults trade guns and other arms. On the other side, German soldiers are very cruel and brutal. What's an example of this? They organise raids on the streets of Warsaw and torture many people in prisons.
In conclusion, the film illustrates different groups of society living in occupied Warsaw during World War Two. It was done in a clever and touching way. The whole movie does come across as true and convincing story in which the society is shown from different perspectives.
Thursday, 3 April 2014
Friday, 14 March 2014
Emacs - set alt as meta key
I had Esc key set as the meta key in Emacs and wanted to change it to have alt key as my meta key. It was done by putting this command to the end of my ~/.emacs file:
(setq x-alt-keysym 'meta)
It wasn't straightforward to find this answer, so this is why I put it on my blog. Enjoy!
(setq x-alt-keysym 'meta)
It wasn't straightforward to find this answer, so this is why I put it on my blog. Enjoy!
Saturday, 1 February 2014
know-how
Jeżeli coś wymaga specjalistycznego know-how, trudno to skopiować, a
wówczas konkurencja na rynku jest niewielka i można dobrze na tym
zarabiać. Naprawdę nie dziwi dlaczego Chiny stają się potężną gospodarką, bo nie każdy może sobie pozwolić na produkcję samolotów czy superkomputerów. Polska nadal nie ma zaawansowanego towaru lub usługi, dla której nie ma konkurencji. Ileż można chwalić się świetną kiełbasą, jabłkami czy innymi mało przetworzonymi produktami. Specjalistyczne know-how można przełożyć także na mniejszy kaliber. Zakładając firmę opartą na prostym modelu łatwym do skopiowania możemy tylko zacząć odliczać godziny kiedy pojawi się silny rywal, a może wystarczy spojrzeć za rogiem, bo pewnie tam nasza konkurencja już jest. Nie pozostaje zatem nic innego jak zacząć wgryzać się w zaawansowane technologie i posiąść właściwe know, a potem wymyślić how.
Tuesday, 28 January 2014
How did you implement a shooting algorithm for the game of Battleship?
Let me describe it a little bit. I took a course on Java programming at my university. I had to implement the game of Battleship in the framework of my project.
The application was divided into 3 parts: model, controller and view (traditional MVC). You could play the game in console using only the model part. The model package (module) contained the main class Model. The Model class contained two attributes of type Player (two players: fist and second) and shotPlayer attribute that denoted the player who could shoot (of type PlayerState). When a shot arrived, the PlayerState object routed the shot to the player that was shot. For example, if first player shot, the PlayerState object routed the shot to the second player.
The PlayerModel class contained the "opponentHit(Point point)" method. Point had two attributes: (x,y) coordinates of the shot. In the method, the shot was sent to the player's board called Sea. The Sea board consisted of fields. Each field had a state:
/** Field is not used. */
UNUSED,
/** Field has been hit and it was a miss. */
MISS,
/** There is a mast and the field has not been hit yet. */
SHIP,
/** There was a mast, but the field has been hit. */
HIT,
/** There was a mast and the ship (which contained the mast) was sunk. */
DESTROYED
Each stated of the field decided on the transition to the next state and the new state was returned. I used the state design pattern here. The coordinates of the point determined the field of the Sea. If the previous state of the field was UNUSED then there was a miss. If the previous state of the field was SHIP then there was a hit. Otherwise, the shot should be repeated.
The code can be found here: https://github.com/adam-dziedzic/battleShips
The application was divided into 3 parts: model, controller and view (traditional MVC). You could play the game in console using only the model part. The model package (module) contained the main class Model. The Model class contained two attributes of type Player (two players: fist and second) and shotPlayer attribute that denoted the player who could shoot (of type PlayerState). When a shot arrived, the PlayerState object routed the shot to the player that was shot. For example, if first player shot, the PlayerState object routed the shot to the second player.
The PlayerModel class contained the "opponentHit(Point point)" method. Point had two attributes: (x,y) coordinates of the shot. In the method, the shot was sent to the player's board called Sea. The Sea board consisted of fields. Each field had a state:
/** Field is not used. */
UNUSED,
/** Field has been hit and it was a miss. */
MISS,
/** There is a mast and the field has not been hit yet. */
SHIP,
/** There was a mast, but the field has been hit. */
HIT,
/** There was a mast and the ship (which contained the mast) was sunk. */
DESTROYED
Each stated of the field decided on the transition to the next state and the new state was returned. I used the state design pattern here. The coordinates of the point determined the field of the Sea. If the previous state of the field was UNUSED then there was a miss. If the previous state of the field was SHIP then there was a hit. Otherwise, the shot should be repeated.
The code can be found here: https://github.com/adam-dziedzic/battleShips
Sunday, 29 December 2013
CLASSPATH
This: http://kevinboone.net/classpath.html is really great explanation of the classpath in Java. Worth reading!
Wednesday, 13 November 2013
Essay - how should we behave?
There is no general and final rule
that could establish the way of our behaviour. There were different
philosophical as well as religious concepts that strived to give us a
recipe for life, but without success. Moreover, there is always a
clash between conservative and liberal approaches to life.
Technology seems to be the one of the sources of
frictions between older people and teenagers. The elder are reserved
towards new electronic devices, whereas young generation absorbs them
rapidly and uses them everywhere, especially in public places. In my view, young people should neither
play songs noisily from their smartphones in public places nor
telephone to somebody and talk loudly. It can be really annoying. On
the other hand, sitting there and waiting for somebody or going by
bus and doing nothing can be boring. Then, the person can read
something on a tablet, listen to music using earphones, play a game
or textchat with somebody. It is at least difficult to get to know
somebody in a bus, so why not to catch up with your friends on
Facebook. The best way to solve the problem is to have both sides the
elder and younger to sit there and talk about technology. Maybe, this
time young people could teach something their parents and
grandparents.
We should remember about
individualism. We should not be concerned about other people's
judgement about us. Only then can we be creative and enthusiastic.
Each of us has his or her big value as an individual. We ought to be
aware of that since this forms a fundamental role in our personal and
professional life. I fully agree with this. However, we do not have
to become rebels. The case is to find our own paths in our lives and
follow them even against the odds. Everybody will die someday, so we
have nothing to loose. It is easy to copy others. Although it is
much harder to be innovative, it gives more fun and
satisfaction.
All in all, our behaviour is a result of many factors. Each of us had better find their own path, but at the same time be tolerant and be aware of different opinions. We should inhibit the bubbles created around us by the other people from inflating. We must stay hungry, full of energy and open-minded.
All in all, our behaviour is a result of many factors. Each of us had better find their own path, but at the same time be tolerant and be aware of different opinions. We should inhibit the bubbles created around us by the other people from inflating. We must stay hungry, full of energy and open-minded.
Friday, 8 November 2013
Who is an outcast?
I'm attending an online course on Algorithms, Part II by Robert Sedgewick and Kevin Wayne. I implemented a tool that uses WordNet data to determine an outcast in a group of words. What was interesting about that? There was a file outcast2.txt which contained only two words: von_Neuman and Turing. Here is the result of a test:
Test 1: test outcast() on WordNet digraph
* outcast2.txt
- nouns = Turing von_Neumann
- student outcast() = von_Neumann
- reference outcast() = Turing
It occurs that Turing was an outcast, not von_Neuman. Hmmm, according to the video by Bret Victor http://bit.ly/1d47YgE, if we had listened to all von_Neuman's theories, we all would write code in an assembly language ;)
Location:
United States
Subscribe to:
Posts (Atom)