79203529

Date: 2024-11-19 13:06:49
Score: 0.5
Natty:
Report link

Does it have to be via fmt? Should be fairly straight-forward without:

#include <vector>
#include <iostream>
#include <iomanip>

int main ()
{
    std::vector<int> v = {1,1,2,3,5,8,13,21,34};
    
    for (size_t i = 0; i < v.size(); ++i) {
        std::cout << ((i > 0) ? "|" : "") << std::setfill(' ') << std::setw(2) << v[i] ;
    }
}
Reasons:
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: André