DEV Community

dev.to codes! Collaborative coding experiment: The most liked comment picks the next line of code, day 1

Pascal Thormeier on November 08, 2022

This experiment is inspired by a post on the ProgrammerHumor subreddit, where the original author did this exact thing: The most upvoted comment af...
Collapse
 
ben profile image
Ben Halpern • Edited
emotions = ["πŸ₯²", "πŸ₯°", "πŸ₯Ί", "😫", "🀬", "😞", "πŸ˜…", "😊", "😰"]
Enter fullscreen mode Exit fullscreen mode

(Ruby)

Collapse
 
schemetastic profile image
Schemetastic (Rodrigo)

Congrats!

Collapse
 
schemetastic profile image
Schemetastic (Rodrigo)

A tiny garden in your console!

['🌹','🌻','πŸ„'].forEach(($) => {console.log($.repeat((1 + Math.random() * 10).toFixed()))});
Enter fullscreen mode Exit fullscreen mode

(JS)

Collapse
 
sherrydays profile image
Sherry Day
let chanceOfSuccess = Math.random();
Enter fullscreen mode Exit fullscreen mode

(JS)

Collapse
 
phlash profile image
Phil Ashby

#! /usr/bin/env python3
Unless anyone fancies writing a polyglot of course!

Collapse
 
alinp25 profile image
Alin Pisica


const getRandomNumber = () => 13

(JS)

Collapse
 
peteole profile image
Ole Petersen
function getValidProgrammingLanguages(task="webdev"):Set<string>{
Enter fullscreen mode Exit fullscreen mode

(Typescript)

Collapse
 
_firelinks profile image
Mike Dabydeen
package main

import "fmt"

func main() {
    fmt.Println("LFG")
}
Enter fullscreen mode Exit fullscreen mode

I choose Go

Collapse
 
orliesaurus profile image
orliesaurus
emotions.shift()
emotions.push("πŸ‘‘")
Enter fullscreen mode Exit fullscreen mode
Collapse
 
nicolus profile image
Nicolus
<?php
Enter fullscreen mode Exit fullscreen mode
Collapse
 
mhcrocky profile image
mhcrocky

Cool idea!
Thanks a lot. I will think about it in near future.