Giter VIP home page Giter VIP logo

qr's Introduction

Repository logo

QR

Program to solve the QR Code Challenge

Repo size License


QR Code Challenge

Problem

"We found a very strange image and we suspect it is a kind of code, but we couldn't break yet. Are you capable to solve it?"

Step 1

Solution

To solve this problem I figured out that I could crop the image in small squares and ensemble them like a jigsaw.

To do so, I used the data structure: Tree.

After obtaining the small squares the steps were the following:

Step 1

Obtain the first line, knowing that a QR has 3 main squares.
Each piece of the puzzle had a color square that matches exactly with at most 2 more

Step 1

Step 2

Get the following line to verify the algorithm was working correct

Step 2

Step 3

Continue testing the algorithm, while seeing if the QR was appearing on the screen

Step 3

Step 4

Complete the jigsaw part of the algorithm. And magically I saw a QR, but I needed to remove those red lines and the color squares.

Step 4

Step 5

Removing the red lines

Step 5

Step 6

Tried to remove the color squares without success

Step 6

Step 7

Lastly, I tried another approach and a clean QR was ready to scan!

Step 7

The QR is not working anymore but, after scanning it, a popup with a message appeared, and that was the code to solve the challenge.

Installation

To run this program locally, download the repository and run the file setup.sh. This file will do the whole installation for you.


License

MIT

qr's People

Contributors

lhbelfanti avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.