How do colleges see retaken class that used to be an F?

In my second semester in community college I took a Calculus class that I just wasn’t prepared for and I didn’t take seriously. I ended up failing the class, but retook it and got an A. This was two years ago and I was young and stupid and wasn’t self-disciplined enough to handle that class. But I currently have been getting A’s in everything else and I really want to apply to higher tier universities for physics but I’m afraid that F will weigh my app down. Does anybody here know how the admissions committees in most bigger universities look at classes that were retaken for a higher grade?

I think at most they will consider both grades (part of the overall GPA). But the usual answer is “it depends on the school”.