Around 18th century, Peter the Great opened Czarist Russia to the West. As you imagine, the immediate result of this move was that the commerce and economy between Czarist Russia and Western European countries flourished. At that time, Arthur Guiness had just took “Porter” recipes from England to Ireland while he increased the dark, coffee-tinted profile of the style. He also added “Extra Stout” sign on the label of Guiness beer, which makes him the founder of the new beer style called “Stout”.

Image for post
Image for post
Photo by Laura Chouette on Unsplash

In 1698, Peter the Great travelled to England and tasted stout. He immediately adored it and he…

In this article we will create a European roulette in SwiftUI. During the process we will learn about animations, structs, enums and state variables.

Image for post
Image for post

As Wikipedia states:

“Roulette is a casino game named after the French word meaning little wheel. In the game, players may choose to place bets on either a single number, various groupings of numbers, the colors red or black, whether the number is odd or even, or if the numbers are high (19–36) or low (1–18)”

The European roulette has 37 distinct pockets (numbered 1 to 36) and a green pocket marked 0 (zero).

So the…

As you may already know Swift is a really modern and powerful language. However, many times we may face difficulties and / or problems during the development process, that Swift cannot handle properly all by herself. Actually most of the times it does but in the end of the day it may not achieve it in the most efficient way. And that’s the point where Swift libraries comes in.

Swift’s native tools and classes for network layer handling such as URLSession, HTTPURLResponse etc, have been better and better over the years. However, there are many libraries out there making things…

Image for post
Image for post

I am not a financial, investment or legal advisor. All views expressed in this article are only that and nothing more, just my views, and their only purpose is to entertain you. Do not take investment advices from random guys on internet. Always talk to a certified advisor.

COVID-19 pandemic has already caused tremendous economic consequences worldwide. In the beginning of the pandemic global markets fell sharply (but then most of them recovered rather fast) as economies “slowed down” and demand for goods and commodities diminished. However, as in every crisis investment opportunities emerged. …

Image for post
Image for post

In the previous part, we covered

  • XSS Attacks
  • SQL injections
  • RegEx Denial of Service

In this part, we will cover

  • Cross-Site Request Forgery Attacks (CSRF)
  • Rate Limiting
  • Data Sanitization

Cross-Site Request Forgery

Cross-Site Request Forgery according to OWASP

Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted actions on a web application in which they’re currently authenticated. CSRF attacks specifically target state-changing requests, not theft of data, since the attacker has no way to see the response to the forged request.

In order to prevent this kind of attack, we should implement a synchronized CSRF tokens policy.

Image for post
Image for post

Swift brought more power to a feature already known from the Objective-C days, enumerations.

However, unlike Objective-C enums which could enumerate related names only to Integer values, Swift enums are much more flexible and do not obligate the developer to provide a value (also known as a “raw value”) for each and every case as Objective-C enums did.

Swift enums also come with associated values, computed properties, instance and methods, initializers, conform to protocols and many more features that empower them to use them as models for our data. Yes, we can use enums almost as we can use classes…

You can easily reverse a string in python like this:

This syntax reverses the string by converting it to an array (in python strings are actually arrays of characters) and then slicing it The syntax for the array slicing is as follows: [start:end:step] where empty start means 0 and empty stop means the length of the array. So [::-1] means to slice the array from the 1st element to the last element in reverse order.

Hope you enjoyed!

Stay tuned for more coding tips.

Image for post
Image for post

As you may already know, one of the biggest troubles in Swift and iOS development is retain cycles. Retain cycles are the causes of another major pain: Memory leaks. A retain cycle is caused every time 2 or more objects hold a strong reference to each other. Swift uses a mechanism called Automatic Reference Counting (ARC) in order to manage memory (allocations / deallocations etc.) . As the name suggests, in Layman’s terms ARC counts how many strong references of an object exist in memory and when the count for an object is 0, then ARC deallocates the memory it…

As you may already know the initials stand for “India Pale Ale” and as many beer styles, this one emerged from a specific need. The hoppy beer that you may enjoy today in a pub or with an original Mexican plate has a really interesting and long history starting back to the early eighteenth century. IPA is the beer shipped to the eastern countries of British Empire and mainly India. The British Indian Army was thirsty for English beer but due to the tropic and hot climate, the brewing process in India was not an option. So, the only way…

Beer, as many drinks, has a so long history that humanity is unable to trace completely.
The first time beer is recorded in history seems to be in ancient Egypt around 5.000 B.C. but there are strong evidence that it existed millennia before. However Egyptians were the first civilization that recorded and documented the brewing process on papyrus.
Since then, this amazing drink has evolved enormously and it continues evolving until today.

Image for post
Image for post

Sometimes my friends say that I am an original “Zythophile” , a word coming from Ancient Greek ζῦθος (zûthos, “barley beer”) + phile, from ancient Greek φίλος (phílos…

Petros Demetrakopoulos

💻Code-blooded, 🌏 Traveler ⌨️ Computer Science graduate, AUEB alumnus. Passionate Homebrewer🍺. Lifelong learner 📚.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store