#include <iostream>
using namespace std;

int main() {
    int m, n, k;
    cin >> m >> n >> k; 

    int count = 0;
    for (int i = 0; i < m; i += k) { 
        for (int j = 0; j < n; j += k) { 
            count++; 
        }
    }

    cout << count; 
    return 0;
}
