When constructing a superscript box or a subscript box, TeX will automatically append a kern of \scriptspace to the end of that hbox. And if you write a double subscript, say, $A_{i_k}$, then there will be two \scriptspaces, which creates too much white space on the right.
How can you get rid of just one \scriptspace?
\documentclass{article}
\begin{document}
For $i_1$, $i_2$,~$\ldots$, and~$i_k$, we have
\[
P(A_{i_1}\cap A_{i_2}\cap \cdots \cap A_{i_k})
=P(A_{i_1}) P(A_{i_2}) \cdots P(A_{i_k}).
\]
\end{document}
\newcommand{\dsub}[2]{_{#1_{#2}}\hspace*{-1\scriptspace}}used withA\dsub{i}{1}maybe? (Though that might be annoying.) – frabjous Sep 16 '22 at 02:14$A\dsub{i}{1}^c$for the complement of$A\dsub{i}{1}$. You certainly would want the^cto attach to theAinstead of the negative space, wouldn’t you? The second reason is somewhat philosophical: It’s “logically more natural” to put the negative space inside (see https://tex.stackexchange.com/q/616371). – Ruixi Zhang Sep 16 '22 at 18:33