Talk:Block (programming)
| This article is rated Start-class on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | ||||||||||||||||||
| ||||||||||||||||||
Suggestion for a small change
The sentence to be changed (perhaps): Currently (in the "Latest revision as of 19:50, 13 November 2024" version of this article), the second sentence of the article says: Blocks consist of one or more declarations and statements
An idea for changing that sentence: I recommend using a singular noun as the subject of the sentence ("A block" instead of "Blocks"), and specifying a separate number -- zero! -- for the minimum number of declarations per block, while retaining (keeping) the number "one" as the minimum number of statements in a block. The sentence could instead say: A block consists of zero or more declarations and one or more statements
That sentence would then offer more (correct) information, and less [potential] ambiguity. IMHO there would be no harm in (thus) making the sentence easier to [correctly] parse, and harder to misinterpret. Any comments? Thanks, -- Mike Schwartz (talk) 21:26, 16 February 2025 (UTC)
- Yes :) Don't use heavy formatting in the talk page. I simplified your comment for readability. ... Yes, singular is usually better than plural even though _many_ people use plural. I often change plural to singular. ... I deleted that sentence since it is low value and confusing. A declaration _is_ a statement! Saying a block is statements is all we need to say, and the first sentence says that. Stevebroshar (talk) 23:27, 3 September 2025 (UTC)
Rename suggestion
IMO the current name Block (programming) is not great and could be better. Consider that there is a Block programming that has nothing to do with computer programming. I've noticed some pages have been renamed from XXX (programming) to XXX (computer programming), and I think that is a good change and a good trend. Therefore, we should consider that change here. But, IMO a good way to choose a disambiguation phrase for a title is to pick a prefix that is 1) well-known; preferably has its own article and 2) is commonly used or at least sounds good with the root topic name. In this, case computer programming block is OK, but I think source code block sounds even better so I propose Block (source code). Stevebroshar (talk) 12:21, 7 September 2025 (UTC)
Content Disclaimer
Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.
- The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
- There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
- It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
- Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
- Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.