code
Mar 17, 2026EVAL-20260317-020940This Go code processes orders concurrently but occasionally produces incorrect totals. Find and fix all concurrency issues. ```go package main import ( "fmt" "sync" ) type OrderProcessor struct { totalRevenue float64 orderCount int errors []string } func (op *OrderProcessor) ProcessOrder(amount float64, wg *sync.WaitGroup) { defer wg.Done() if amount <= 0 { op.errors = append(op.errors, fmt.Sprintf("invalid amount: %.2f", amount)) return } op.totalRevenue += amount op.orderCount++ } func main() { op := &OrderProcessor{} var wg sync.WaitGroup orders := []float64{99.99, 149.50, -10.00, 299.99, 49.99, 0, 199.99} for _, amount := range orders { wg.Add(1) go op.ProcessOrder(amount, &wg) } wg.Wait() fmt.Printf("Total: $%.2f from %d orders\n", op.totalRevenue, op.orderCount) } ```
Winner
Qwen 3.5 122B-A10B
openrouter
9.77
WINNER SCORE
matrix avg: 9.47
10×10 Judgment Matrix · 53 judgments
OPEN DATA
| Judge ↓ / Respondent → | Qwen 3.5 9B | Qwen 3 8B | Qwen 3 32B | Qwen 3 Coder Next | Qwen 3.5 35B-A3B | Qwen 3.5 27B | Qwen 3.5 122B-A10B | Qwen 3.5 397B-A17B |
|---|---|---|---|---|---|---|---|---|
| Qwen 3.5 9B | — | 8.4 | 8.3 | 8.6 | 9.6 | 8.8 | 9.0 | 9.0 |
| Qwen 3 8B | 10.0 | — | 10.0 | 9.8 | 10.0 | 10.0 | 10.0 | 9.8 |
| Qwen 3 32B | 9.8 | 9.8 | — | 10.0 | 9.2 | 10.0 | 10.0 | 9.8 |
| Qwen 3 Coder Next | 10.0 | 10.0 | 10.0 | — | 10.0 | 10.0 | 10.0 | 9.8 |
| Qwen 3.5 35B-A3B | 9.3 | · | 9.8 | 8.6 | — | 9.3 | 9.8 | 9.3 |
| Qwen 3.5 27B | 8.3 | 9.4 | 9.6 | 7.5 | 9.6 | — | · | 9.6 |
| Qwen 3.5 122B-A10B | 8.3 | 9.6 | 9.4 | 9.6 | 9.8 | 8.8 | — | 9.2 |
| Qwen 3.5 397B-A17B | 8.6 | 9.6 | 9.6 | 9.6 | 9.8 | · | 9.8 | — |