\documentclass[a4j]{ltjsarticle}
\usepackage{listings}
%
\title{プログラミング基礎レポート \\ (出題日: 2025年4月1日)}
\author{1W24XXXX 柏木 雅英}
\date{2025年4月1日}
%
\begin{document}
%
\maketitle
%
\section{問題}
%
XXXするプログラムを作成せよ。
%
\section{プログラム}
%
\begin{lstlisting}
#include <stdio.h>

main()
{
    int x, i;

    scanf("%d", x);

    ...

    printf("%d is a prime number\n", x);
	
}
\end{lstlisting}
%
\section{実行結果}
%
\begin{lstlisting}
Please type a number: 29
29 is a prime number
Please type a number: 91
91 is not a prime number
\end{lstlisting}
%
\section{解法とプログラムの解説}
%
$2$以上$x$未満の全ての数で割ってみて、...

プログラムでは、X行目でXXを計算している。...

XXの部分は、\cite{KandR}を参考にした。
%
\section{考察}
%
XXが難しかった。

XXをXXとすれば良かったと思う。
%
\begin{thebibliography}{9}
\bibitem{KandR}
カーニハン, リッチー: ``プログラミング言語C 第2版 ANSI規格準拠'',
共立出版 (1989) .
\end{thebibliography}
\end{document}
