結果

問題 No.3296 81-like number
コンテスト
ユーザー ID 21712
提出日時 2025-10-19 18:26:13
言語 Go
(1.23.4)
結果
WA  
実行時間 -
コード長 241 bytes
コンパイル時間 12,569 ms
コンパイル使用メモリ 248,536 KB
実行使用メモリ 7,716 KB
最終ジャッジ日時 2025-10-19 18:26:28
合計ジャッジ時間 14,007 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample WA * 3
other AC * 2 WA * 13
権限があれば一括ダウンロードができます

ソースコード

diff #

package main

import . "fmt"

func main() {
	var n int
	Scan(&n)
	var f [1e5+1]bool
	cnt:=0
	for p:=2;p*p<=n;p++ {
		if f[p] {
			continue
		}
		for k:=p;k*k<=n;k+=p {
			f[k]=true
		}
		for t:=p;t*p<=n;t*=p {
			cnt++
		}
	}
	Println(cnt)
}
0