Contest

Syndicate content 2 

Advent of Code is a series of 25 small programming challenges, it's an ideal way for beginners to start learning a computer language, and for advanced people to sharpen their programming skills.

There are small and bigger puzzles, which you can solve typically in half an hour to a few hours. (Looking at the leaderboard, the top aces can do them in less than 10 minutes.)

Advent of Code is created by Eric Wastl, you can find all info on https://adventofcode.com/.

To help you get trained for this year's challenges which start at December 1st, we* will try to solve and comment the puzzles from 2016. (we = Bert Sarens and myself)

Each day, you get two puzzles, where the second one is usually a slight variation on the first one, which shows you how your code will cope with requirement changes or other input (in some cases by having to completely rewriting your code !)

+ 6   0 5
0

comments

504

views

+ 6

rating

Hello everyone,

 

From now till the 25th of december each day 2 programming problems to sharpen your programming skills.

http://adventofcode.com/

 

Theme this year:

The night before Christmas, one of Santa's Elves calls you in a panic. "The printer's broken! We can't print the Naughty or Nice List!" By the time you make it to sub-basement 17, there are only a few minutes until midnight. "We have a big problem," she says; "there must be almost fifty bugs in this system, but nothing else can print The List. Stand in this square, quick! There's no time to explain; if you can convince them to pay you in stars, you'll be able to--" She pulls a lever and the world goes blurry

Last comment 26 December 2017
+ 5   0 10
794

views

+ 5

rating

Hi Everyone!

As you know Advent of Code 2018 is in full swing! Till the 25th of December 2018 each day 2 programming problems to sharpen your programming skills! 

And now we're ready to present great prizes for Members of InterSystems Global Masters Advocate Hub!

Last comment 2 January 2019
+ 5   0 9
684

views

+ 5

rating

Hi, Community!

Last weekend we held the Final of InterSystems Contest on InterSystems Caché and DeepSee as a part of IT Planet Student Championship in Sochi. BTW, this year we had about 2 000 participants in InterSystems Contest.

One of the tasks for the finals was to solve the following  with Caché ObjectScript and use the minimum code. 

Problem description

Write a method that would return the string 9876543210, however cls code should not contain numbers 0-9.

The goal is to write the shortest method.

Here's a method signature (it can't be modified)

Last answer 8 June 2017 Last comment 8 June 2017
+ 4   0 7
521

views

+ 4

rating

Hey Developers!

Advent of Code 2018 is over! Thanks for participating in our small but productive COS marathon!

And now we're pleased to introduce the winners and distribute all the prizes! 

Big applause goes to these winners: 

     Fabian Haupt (w/ repo: github.com/kazamatzuri/AoC)

     Bert Sarens (w/ repo: bitbucket.org/bertsarens/aoc2018/)

     Dmitry Maslennikov (w/ repo: github.com/daimor/AdventOfCode)

+ 4   0 1
0

comments

93

views

+ 4

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : goto to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

The input in today's challenge consists of an encrypted name, a dash, a sectorID, a dash and a checksum between brackets.
A name is real if the checksum is equal to the five most common letters in the encypted name.


For example : 
aaaaa-bbb-z-y-x-123[abxyz] is a real name because the most common 5 leters are a,b,x,y,z (sorted by numer of occurences and alphabetically)

The challenge is to output the sum of the sectorID's for all the real names

Last comment 8 November 2017
+ 3   0 2
178

views

+ 3

rating

Hi, Community!

The Second Global Summit Free Registration Contest is running and we have only one week to celebrate new winner!

Here is current leaderboard amongst non-InterSystems DC Members after a half of the race:

 

(If you want to see contribution from InterSystems employees just set the filter value in the Deepsee dashboard)

John Murray contributed more than others last week.  John is a leader, but he did the result only for one week! 

There is one week more and so everyone can be a winner!

+ 3   0 0
0

comments

70

views

+ 3

rating

Hi Community!

We try a new approach to Developer Community YouTube Videos called "Coding Talks"!

Coding Talks is a short video in which the developer demonstrates a particular feature or functionality of InterSystems Data Platforms which he/she uses to in coding. Typical format: the face on side and editor with ObjectScript.

Check this video I made by myself participating in Advent of Code 2018 and coding with InterSystems ObjectScript in VSCode.

Coding Advent of Code 2018 Using InterSystems ObjectScript 

 

+ 3   1 2
0

comments

160

views

+ 3

rating

Advent of Code is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : look  at article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

In this challenge, you need to find a password using instructions to move on a keypad.
Instructions can be U(p), D(own), L(eft) and R(ight).

You start at button 5 on a keypad like

1 2 3
4 5 6
7 8 9

each line of instructions lead to one digit of the password.
Full description can be found at http://adventofcode.com/2016/day/2

For example : ULL leads to '1' (a move outside the keypad can be ignored

+ 3   0 1
0

comments

208

views

+ 3

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : goto to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta... or look at the http://adventofcode.com/ website.

 

In today's challenge, you have to find out how many 'valid' triangles you find on the walls of the Easter Bunny HQ.
(you can find the input on the adventofcode website : http://adventofcode.com/2016/day/3/input)

A sample of the input looks like this :

  810  679   10
  783  255  616
  545  626  626
   84  910  149
  607  425  901
  556  616  883
  938  900  621

A valid triangle is a set of three side lengths where the sum of any two sides is larger than the remaining side

Last comment 3 November 2017
+ 2   0 3
221

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

Today's challenge is a variation on the White Elephant gift exchange (https://en.wikipedia.org/wiki/White_elephant_gift_exchange), in this case, by a bunch of Elves where only one can have all gifts.


Each Elf brings a present. They all sit in a circle, numbered starting with position 1. Then, starting with the first Elf, they take turns stealing all the presents from the Elf to their left. An Elf with no presents is removed from the circle and does not take turns.

With 5 elves, the Elf that sits in position 3 gets all the presents

+ 2   0 1
0

comments

124

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : goto to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

The challenge of day 5 is to calculate a password of 8 characters by finding the MD5 hash of the input and an increasing integer index.
The password is constructed by taking the 6th character of the first 8 hashes that start with 5 zeroes (in hex representation).

For example : if the input would be 'abc', the first hash that has 5 zeroes would be by MD5 hashing abc3231929 : the hex representation is 00 00 01 55 F8 ...
The 6th character is 1 and thus the first character of the password

Last comment 8 November 2017
+ 2   0 2
189

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...
 

The challenge of day 21 is about scrambling passwords.

There are a few functions you need to implement that will do operations on a string

+ 2   0 1
0

comments

115

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

Today's challenge is about decompressing input that is compressed in an experimental format.
In the format, markers indicate how much time a number of characters need to be repeated.

For example

Last comment 11 November 2017
+ 2   0 2
255

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

In today's challenge, you have to execute instructions that control how bots are handling microchips.

The input contain instructions that can be something like this :

Last comment 11 November 2017
+ 2   0 2
141

views

+ 2

rating

Hey guys!

Thanks for participating in our small but productive COS marathon on behalf Adventofcode 2017!

The leaderboard is here:

 

And we are ready to announce the winner but need your public repositories with COS solutions inside. Please share it below in comments.

We have results!

1st place: Bert Sarens!  Repository.

2nd place: Peter SteiwerRepository

Last comment 28 December 2017
+ 2   0 5
326

views

+ 2

rating

Hi, Community!

There are only six days left to win InterSystems Developer Community MVP prize.

As it was announced in addition to Free Registration on InterSystems Global Summit winner gets 4 nights stay in the Arizona Baltimore, Waldorf Astoria Resort.

We measure contribution to Developer Community on valuable posts and comments and prepared special leaderboard built on InterSystems DeepSee.

By default, it shows all the members. We added the filter to the dashboard to show leaderboard without members who are InterSystems employees.

So here is current leaderboard without InterSystems members:

  

Last comment 24 February 2016
+ 2   0 1
131

views

+ 2

rating

Are you ready for the next Advent of Code this year?

Just a few days left, the first puzzles will unlock on December 1st at midnight Eastern Time.

Not sure if I will manage to find time to solve those puzzles as quickly as last year, but hope some of you will do. We still have our leaderboard, you can join 130669-ab1f69bf.  So, we will see who the best.

Last comment 8 December 2018
+ 2   0 3
259

views

+ 2

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

We are almost there : after this challenge, only 5 days left till the end of this advent of code (I cannot wait to get my life back !) .

 

The challenge of day 20 is about a list of integer ranges. Some ranges overlap,  but there are also values that are outside any range.

You have to find out what is the lowest integer that is outside any range.
 

More explanation (there is not much more to say) can be found on http://adventofcode.com/2016/day/20, with the link to your puzzle input

+ 1   0 2
0

comments

117

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : goto to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

In today's challenge, you have to repair the communication with Santa : messages are coming in, but jammed.
By using repetition code (see also https://en.wikipedia.org/wiki/Repetition_code), you can find out what's in the message : by sending the same message a number of times, you can calculate which characters are most frequent on each position and find the most likely message.

For example, with input like :

eedadn
drvtee
eandsr
raavrd
atevrs
tsrnev
sdttsa
rasrtv
nssdts
ntnada
svetve
tesnvt
vntsnd
vrdear
dvrsen
enarar

the most common characters in each column are e, a, s, t, e, r

Last comment 8 November 2017
+ 1   0 2
162

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...


The goal of today's challenge is to copy data from one disk to another, problem is that the disks are not directly connected. Luckily they are in a huge grid, and you have to find a way to copy the data through adjacents disks, while honoring the disk usage (you cannot copy to a disk where data is already stored).


The input is a df-like disk usage listing.

The first challenge is to calculate a list of disks that can copy data.

These are all viable pairs of disk nodes (A,B) where

+ 1   0 2
0

comments

146

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : goto to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

Today's challenge on http://adventofcode.com/2016/day/7 is about checking for valid IPv7 addresses with TLS support. (No, it has nothing to do with real ip addresses which are at most ipV6 or real TLS, but just a way to keep you busy coding & hacking!)

The imaginary ipV7 addresses support TLS if they contain an ABBA sequence outside square brackets and no ABBA sequence inside brackets. (ABBA : any 4 character sequence where the first pair are 2 different characters followed by the reverse of that pair).

For example

Last comment 7 November 2017
+ 1   0 2
157

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

The challenge of today has nothing to do with real two-factor authentication ! (sorry if you came to this article by searching the real thing)

For the complete explanation of the challenge, go to http://adventofcode.com/2016/day/8.

Your input (http://adventofcode.com/2016/day/8/input) consists of a series of three basic instructions to control the display of a screen.
The goal of the first part of the challenge is to calculate how much pixels will be lit after all instructions are executed.

The three basic instructions are

Last comment 8 November 2017
+ 1   0 2
120

views

+ 1

rating

This is (the end) of a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

This is the 25th and last challenge of the 2016 series of Advent of Code.

In this challenge,  you have to send a signal out,  using the assembunny code interpreter that  we had to make in earlier challenges.

There is one extra instruction added to the assembunny language, which outputs a value (out x)

Last comment 27 November 2017
+ 1   0 4
189

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

The challenge today is about microchips and generators. A microchip belongs to one particular generator, and the two can be on the same floor, or in the same elevator. But if a microchip is with another generator on the same floor or elevator, it will get toasted, except if his own generator is also on the same floor/elevator.
The elevator has only room for two items (can be mix of microchips/generators), the elevator stops on each floor for one second, enough for a microchip to get toasted if there is another type of  generator on the same floor/elevator and its own generator is not there

+ 1   0 1
0

comments

171

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

Today, you need to make a compiler for the language assembunny.
Luckily, this language has only 4 instructions :

 

cpy x y copies x (either an integer or the value of a register) into register y.
inc x increases the value of register x by one.
dec x decreases the value of register x by one.
jnz x y jumps to an instruction y away (positive means forward; negative means backward), but only if x is not zero.


For example :

cpy 41 a
inc a
inc a
dec a
jnz a 2
dec a

After executing these instructions, the register a would contain 42

Last comment 12 November 2017
+ 1   0 2
146

views

+ 1

rating

#########
#S| | | #
#-#-#-#-#
# | | | #
#-#-#-#-#
# | | | #
#-#-#-#-#
# | | |  
####### V

<!--break-->

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...


The challenge today is again a-maze-ing (as a wellknown president would say).


The maze has a bunch of doors ( | and - on the drawing), but they can be locked depending on a hash that you need to calculate every step. When you visit a location a second time, the lock on each door can be different from the previous time !


The way to know that a door is locked

+ 1   0 1
0

comments

132

views

+ 1

rating

This is a series of programming challenges for beginners and experienced Caché programmers.

For an introduction : go to article https://community.intersystems.com/post/advent-code-2016-day1-no-time-ta...

 

You walk into a room, step on a tile and hear a loud click...

Traps !

The challenge is about avoiding traps.

 

You can recognise if a tile is a trap by following scheme :

The first row is a given : a safe tile is shown as . and a trap is shown as ^
For the next rows, the state of a tile is calculated related to the tiles in the previous row (same position, tile left and tile right).
If the tile is at an edge, the non-existing tile at the previous row outside the edge is considered safe.

This is how you can calculated if a tile is safe or trap while looking at the tiles on the previous row

+ 1   0 1
0

comments

92

views

+ 1

rating