1

I googled myself a little to see which article is more commonly used with types, and I understood one commonly uses a to indicate a general type such as integer.

But what about a specific type such as a structure? For example, which one should I use when I'm writing a sentence like below?

A: Assume a delegate pointer is a T type.

B: Assume a delegate pointer is the T type.

I used T to denote the name of a specific data type. Both look somewhat awkward for me, since A is like it's indicating one of many T types (which is not), and B looks a little redundant due to the.

Some might suggest I can simply write

Assume a delegate pointer is T,

but I'd rather make it clear that the T I'm using is a kind of type.

2

What I'd say is

Assume a delegate pointer is of type T.

In casual conversation, I might say any of the following:

Assume a delegate pointer is a T.

Assume a delegate pointer has a type of T. (best)

Assume a delegate pointer has the type T.

Assume a delegate pointer has type T.

but these all sound less CS-like.

| improve this answer | |
  • Thanks a lot! I also wondered if I can say 'type T' without an article. :] – Gwangmu Lee Dec 19 '19 at 5:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.