List<DateTime> list = new List<DateTime>();
Currently i have the following syntax:
if(list[list.Count - 1] != list.[list.Count - 2])
{
//do something
}
This is a incredible long syntax (in my real program the list name is a lot longer as well). The list is also available trough a static method which even increases the width of this syntax by quite a bit.
How can i write this syntax shorter and more readable?
Thanks!
1 Answer