Defining my own proof environment?
With LaTeX syntax:
\newenvironment{proof}{\paragraph{Proof:}}{\hfill$\square$}
I assume here that you mean \hbox{}
not \box
in your code.
The \null
macro is short for \hbox{}
. The \box
is a TeX primitive and is more like \usebox
.
You can also use the amsthm
package which is a really nice and quick way of creating a proof.
Implementation
\documentclass{article}
\usepackage{amsthm}
\begin{document}
\begin{proof}
Your proof here.
\end{proof}
\end{document}
It will add Proof
in italics at the beginning of the text given as argument and a white square (Q.E.D. symbol) at the end of it.
I found this easy solution at 1. You can also look up there how you define your own environments using this package.
A small extension due to the case that the proofs are in the section "Proofs:"
\documentclass[11pt]{amsart}
\newtheorem{pro}{Proposition}[section]
\newtheorem{theo}[pro]{Theorem}
\newenvironment{myproof}[2] {\paragraph{Proof of {#1} {#2} :}}{\hfill$\square$}
\begin{document}
\begin{theo} \label{theo}
Hello
\end{theo}
\begin{myproof}{Theorem}{\ref{theo}}
This is the proof
\end{myproof}
\end{document}