제출 #1098949

#제출 시각아이디문제언어결과실행 시간메모리
1098949ohadBoarding Passes (BOI22_passes)C++14
0 / 100
1 ms344 KiB
#include <iostream>
#include <vector>
#include <cmath>
#include <iomanip>
#include <stdio.h>
using namespace std;
typedef long double ld;

int main() {
	string a;
	cin >> a;
	int size = a.length();
	int l = 0;
	ld b = size / 2;
	ld c = (size + 1) / 2;
	ld x = (c * (c-1)) +(b*(b-1)) / ld(4);
	cout << fixed << setprecision(6) << x;
}

컴파일 시 표준 에러 (stderr) 메시지

passes.cpp: In function 'int main()':
passes.cpp:13:6: warning: unused variable 'l' [-Wunused-variable]
   13 |  int l = 0;
      |      ^
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…