알고리즘

[알고리즘] 백준 17496 - 스타후르츠 (C++)

blueberrysoda 2024. 10. 5. 23:50

[문제 링크] : https://www.acmicpc.net/problem/17496

#include <iostream>
using namespace std;

int main(){
    int N, T, C, P;
    cin >> N >> T >> C >> P;
    cout << (N-1) / T * C * P << "\n";
    return 0;
}