Acerca del objeto DateTime

17/04/2007 - 21:33 por Harvey Triana | Informe spam
Si yo escribo algo como:

public struct WITSTable
{
public DateTime t;
public float v;
}
const int COUNT = 100000;
WITSTable[] a = new WITSTable[COUNT];

El peso del array es considerable. ¿Existe una manera más eficiente de
escribir esto?
Si yo escribo en Visual Basic clásico:

Public Type WITSTable
DateTime As Date
Value As Single
End Type
Private Const COUNT As Long = 100000
Private a(1 To COUNT) As WITSTable

El peso del array es ligero.

Corolario

Quisiera que existiera un tipo en .NET que almacenara tiempo en solo 8 bytes
por variable.

Su servidor,
<Harvey Triana />
 

Preguntas similares