2

What is the difference between the following sentences? Are both correct? If both are correct, which is more popular?

The function imread reads images.

The imread function reads images.

Note that "imread" is the name of the function, and that the difference is the order of the words "function" and "imread". I have seen both constructions repetitively in software manuals and source code comments.

5
  • 2
    One question per post please. Commented Apr 4, 2018 at 17:58
  • 4
    But conversely, when there is a name, it is common to precede the name by a classifier: "the book Paradise Lost, the film Aliens, the mountain Kilimanjaro". "The function imread" is a very common pattern in technical manuals.
    – Colin Fine
    Commented Apr 4, 2018 at 18:31
  • Please post your other question as a separate post.
    – user230
    Commented Apr 4, 2018 at 20:41
  • My comment above was a reply to a comment which has since been deleted. The upshot is that there is plenty of precedent for both ways round.
    – Colin Fine
    Commented Apr 4, 2018 at 23:05
  • Just to give you an example. The page contains both "the built-in function len()," and "the print() function."
    – x-yuri
    Commented Aug 18, 2020 at 19:02

1 Answer 1

2

I'm know quite a bit about coding and can confirm that both are correct.

Personally if I was going to talk about that function to other programmers then I would say "imread function" but, if I was going to create some documentation about it (this would be a more formal context) then I would put "function imread".

TLDR - Both are correct. If I had to, I'd say "function imread" is more formal but it really doesn't make much of a difference.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .