aboutsummaryrefslogtreecommitdiff
path: root/sway/util.c
blob: 9a59ddf9155b7398dd139e23d51874fb0b5f3120 (plain)
1
2
3
4
5
#include "util.h"

int wrap(int i, int max) {
	return ((i % max) + max) % max;
}