Linked Questions

10 votes
2 answers
151 views

Should rust anonymous functions fully specify parameter types? [duplicate]

Context Rust does a lot of smart things to determine the types of variables. This is why you rarely need to define the types of a variable explicitly. Rust can search very far to find a type for a ...
mousetail's user avatar
  • 11.8k
0 votes
0 answers
69 views

Can lambda parameter types be left off if potentially inferable from context? [duplicate]

This Java answer (and this one) uses a lambda that does not explicitly declare its parameter type, but this Scala answer includes a parameter type. in both cases, the type could be inferred when it is ...
Brian McCutchon's user avatar
2 votes
0 answers
48 views

Can we assume typed inputs? [duplicate]

For some languages with a static type system the compiler is able to infer the types, however sometimes there's ambiguity (even with input) unless the user gives the type manually: Motivation 1: ...
ბიმო's user avatar
  • 16.7k
58 votes
7 answers
1k views

A proposal to combat Meta Bloat™: The Big Consensus Freeze

I believe it's a widely acknowledged problem in this community that the number of meta posts a new user needs to know to figure out all the rules has long got out of hand. We require certain answer ...
Martin Ender's user avatar
23 votes
3 answers
754 views

Can and should we encourage more meticulous golfing?

I find that much of the joy and art of code golf comes from the ridiculous tricks and optimizations needed to squeeze every character. Yet, I find myself losing motivation to do so because I feel like ...
xnor's user avatar
  • 144k
22 votes
1 answer
2k views

Are we allowed to use empty input we won't use when no input is asked (regarding functions)?

Let's say a code-golf challenge is asking for a program without arguments or function without parameters. Are we allowed to take an empty parameter instead we won't use anywhere? As example: In Java ...
Kevin Cruijssen's user avatar
5 votes
2 answers
2k views

Java function literals

In this meta post, it's decided that function literals are valid when a function is required. What about lambda expressions in Java 8? These are similar to function literals in other languages, but ...
Ypnypn's user avatar
  • 10.8k
10 votes
3 answers
542 views

Byte count for named, recursive lambda expressions in C# answers

I have been questioned about the byte count in my C# answer for the The Snail in the Well challenge. Usually C# answers only need to count the following bytes: ...
Charlie's user avatar
  • 12.8k
9 votes
1 answer
398 views

Scoring Java lambdas with imports [duplicate]

In this answer, I used a java.util.List as a parameter to an anonymous function (lambda) answer. So, my question is, Should this import be counted to the byte ...
CAD97's user avatar
  • 1,337
9 votes
2 answers
523 views

C# Lambdas as Answers to questions asking for a Function

Edit: I've broken the proposal out into an answer, but left the examples where they are. Please do not consider a vote for this question to constitute support for the proposal Apologies in advance, ...
VisualMelon's user avatar
  • 3,878
3 votes
1 answer
112 views

Are multi-method solutions allowed in Java?

I recently joined this community as a Java golfer, and I haven't been able to find a definitive consensus on acceptable solution formats for Java. From what I gather, the following are allowed (...
Jakob's user avatar
  • 2,719
1 vote
1 answer
114 views

What counts towards the byte count in a code golf answer?

I use Racket as my primary programming language and have been having fun the past week solving challenges using it. I came across a few answers from other programming languages that use TIO's header ...
Ed The ''Pro'''s user avatar
1 vote
2 answers
94 views

Should creating a new lambda class be allowed?

Preface This question is specifically targeting Java answers. I have little to no knowledge of any other program languages, though I expect that the questions I ...
Socratic Phoenix's user avatar
-2 votes
1 answer
100 views

Language-Specific Boilerplates to Formalise Submission Validity (in atleast some languages)

I'll try to keep this short... see these (relatively recent) questions for some background: 1 2 3 Disclaimer: I really hate 'untyped anonymous lambdas', and if we must have them, then we need some ...
VisualMelon's user avatar
  • 3,878
2 votes
2 answers
114 views

Multiple functions without leading/trailing mandatory parts?

Are we allowed to have multiple functions without the verbose Func-parts which are calling each other as code-golf submission? For example, in Java 8+ this is an allowed answer based on the current ...
Kevin Cruijssen's user avatar