#include <bits/stdc++.h>
int main() {
  double a, b, x, y, temp = 0;
  scanf("%lf%lf", &a, &b);
  long long int n;
  scanf("%lld", &n);
  long long int ans = 1, nn = 0;
  while (ans <= n) {
    nn = ans * b / a;
    temp = ans * b - nn * a;
    switch (nn % 4) {
      case 0:
        x = temp;
        y = 0;
        break;
      case 1:
        x = a;
        y = temp;
        break;
      case 2:
        x = a - temp;
        y = a;
        break;
      case 3:
        x = 0;
        y = a - temp;
        break;
    }
    printf("%.10lf %.10lf\n", x, y);
    ans++;
  }
}
