---
title: "Discussion on \"Advent of Code 2020: Day 13 (Ruby solution)\" | Hashnode"
description: "Discussion on \"Advent of Code 2020: Day 13 (Ruby solution)\". Today's puzzle is not so easy.\nThe first task is about finding the closest arrival timestamp knowing how often each bus courses. This part is trivial:\nfile = File.read('inputs/day13.txt')\ntimestamp = file.lines.first.to_i\nbus_lines = file.lines.last...."
url: "https://hashnode.com/posts/advent-of-code-2020-day-13-ruby-solution/5fd693b427af257395892432"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Advent of Code 2020: Day 13 (Ruby solution)](https://rubywizards.com/advent-of-code-2020-day-13-ruby-solution?utm_source=hashnode&utm_medium=feed)

Today's puzzle is not so easy. The first task is about finding the closest arrival timestamp knowing how often each bus courses. This part is trivial: file = File.read('inputs/day13.txt') timestamp = file.lines.first.to\_i bus\_lines = file.lines.last....

Dec 13, 2020 · 2 min read · rubywizards.com  
Updated Apr 13, 2021  
Read the article

-   [#ruby](https://hashnode.com/tag/ruby)

## Written by

[Piotr Jurewicz](https://hashnode.com/@pjurewicz)

@pjurewicz · Łódź, Poland

  
[View profile](https://hashnode.com/@pjurewicz)

ruby on rails developer

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
