aboutsummaryrefslogtreecommitdiff
path: root/src/2021/day9/aoc.cpp
blob: d8f6735948c49732fae6bdccc0ad04296dd11b16 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include "aoc.h"

namespace aoc2021 {

std::pair<int, int> day9(line_view file) {
  heightmap hm;
  int r{0};
  per_line(file, [&r, &hm](line_view lv){
    hm.load(r, lv);
    r++;
    return true;
  });

  return {hm.risks(), 0};
}

}