the naive version