/dpt/ - Daily Programming Thread

What are you working on, Sup Forums?

Old thread:

Other urls found in this thread:

youtube.com/user/TheChernoProject
youtube.com/watch?v=Pw3wrVBhZ6M
twitter.com/NSFWRedditGif

first for java

First for why the fuck wont Sup Forums let me post long replys

pump

Should I pick up C++?

What's a good book for learning it?

What project can I do for learning? any clues?

First for Ruby

youtube.com/user/TheChernoProject

unsafe

All else has failed, I am a broken man.

Anyway, here's a function to turn numbers into roman numerals. Let me know if you have any reccomendations to improve it!

Rate my fizzbuzz
(1..100).each{|n|
z = ""
z += "Fizz" if n % 3 == 0
z += "Buzz" if n % 5 == 0
print z+" " if !z.empty?
print n.to_s+" " if z.empty?
}

Is it true that C++ is the best or it's just a meme?

...

Agda is the best language

>waaaahhh I can't be an annoying edgy twit

theres no web dev gen

I'm starting my journey into web dev for my senior project in college. I'm doing all the devops on AWS, any recommended tutorials / books?

why did you do it this way

Mein Kampf

How come every single project and ardent proponent of rust is a tranny or a problem glasses wearing SJW?
You should also see the way rust devs argue, they don't even attempt to accept responsibility, they just gang up on you, apply critical theory and attack you with ad hominems until you leave.
I don't notice this with any other programming language community, why does rust attract people like this exclusively?

youtube.com/watch?v=Pw3wrVBhZ6M

B-but reddit told me that this channel gives factually wrong information. Who should I listen to?

Mine's better:
#include
#include
#include

void fizzbuzz(int n)
{
if (n

>why does rust attract people like this exclusively?
Because it's the exact kind of people Mozilla want for whatever reason. The word "cult" gets thrown around here a lot in shitposts, but I truly believe Rust and its majority are a new age cult.

What is your most starred github project, /dpt/?

195 stars here.

Here's one I prepared earlier
fix ("","",z) = show z
fix (x, y, _) = x ++ y

fizz x = map fix (take x (zip3 (cycle ["","","Fizz"]) (cycle ["","","","","Buzz"]) (cycle [1..])))

The practical benefit is that you can assert equality between reals directly instead of just asserting "closeness".

>why does rust attract people like this exclusively?
Do you mean why are they attracted by exclusively Rust? Because plenty of normal people seem to be using it, they just don't participate in the community much (for obvious reasons). Those trannies cannot be responsible for the numerous actually useful published crates.

Why do you cycle [1..] . I don't know much haskell, but doesn't cycle make a list infinite by cycling it?

Anger at and hatred of Rust is invariably driven by bitterness and regret over a life spent accumulating a C++ skillset that is rapidly becoming obsolete.

Least bad maybe, if you care about performance.
C may make more sense though depending on your needs, and while it is a bit clunky for some things it's clean and elegant compared to the mess that is C++.
What more can we add to the fucking language?

Playing with x86 assembly.
Wanna swap bits around, like even bits for odd bits I.e 01100100 will turn into 10011000

Easiest way to do this?

No.

>}
>else
>{
disgusting

Yes.

This is easily optimized as it is just a string-substitution.
The Caesar cipher is one of the earliest known and simplest ciphers. It is a type of substitution cipher in which each letter in the plaintext is 'shifted' a certain number of places down the alphabet. For example, with a shift of 1, A would be replaced by B, B would become C, and so on.

Optimization pending.

This community is committed to providing an engaging, inviting, and welcoming experience for all.//該社區致力於提供一個接合,邀請,並歡迎所有的經驗。//该社区致力于提供一个接合,邀请,并欢迎所有的经验。

PHP/Javascript+jQuery+Velocity(Graphical Plugin)/CSS/HTML. Payload complete.

Unpleasant discourse. Unproductive.

I.

Verbosity ? Clarity

Authorized.

Incorrect Language

Linguistic bastardizations.

(n/2)*-1

Unit tests, same as yesterday

This guy is good

I give it a weird / 10

friend(o)

#include

int64_t fizzbuzz(uint8_t n)
{
if (n 92) return -1;
n -= 2;

uint64_t a = 1, b = 1, c = 0, d = 1, e = 1, f = 0;

while (n) {
uint64_t g, h;
if (n & 1) {
g = a * d + b * e;
h = b * d + c * e;
f = b * e + c * f;
d = g;
e = h;
}
g = a * b + b * c;
a = a * a + b * b;
c = b * b + c * c;
b = g;
n >>= 1;
}

return d;
}

零,朋友(O)

Fizzbuzz, linguistic inference. Query, optimization via occularity? Periodicity breach.

One-liner BF required.

An eso-lang where all your programs are a type of fizzbuzz,

? roman numerals aren't comparable to ceasar ciphers. I don't understand

if args[1] == "left":
left()
elif args[1] == "right":
right()
elif args[1] == "top":
top()
elif args[1] == "bottom":
bottom()


How to write this in Python is a less pajeet way?

Brainfuck is an esoteric programming language created in 1993 by Urban Müller, and notable for its extreme minimalism.

The language consists of only eight simple commands and an instruction pointer. While it is fully Turing-complete, it is not intended for practical use, but to challenge and amuse programmers. Brainfuck simply requires one to break commands into microscopic steps.

The language's name is a reference to the slang term brainfuck, which refers to things so complicated or unusual that they exceed the limits of one's understanding.
//
Brainfuck是其極端簡約的城市穆勒在1993年創造了一個深奧的編程語言,並顯著。

語言包括只有八個簡單的命令和指令指針。 雖然這是完全圖靈完備的,它不適合實際使用,但挑戰和逗程序員。 Brainfuck只需要一個突破命令到微觀的步驟。

語言的名字是俗話期限brainfuck,指事情太複雜或不尋常的,他們超過一個人的理解範圍的參考。

Then Kaiser Is Pleased.

mods, can you please ban the chink bot.

MODS的,可以請你禁止縫隙機器人。

如果ARGS [1] ==“左”:
左()
的elif ARGS [1] ==“右”:
右()
的elif ARGS [1] ==“頂部”:
頂()
的elif ARGS [1] ==“底部”:
底部()


如何寫這個在Python是一個不太pajeet方式?

>How to write this in Python is a less pajeet way?
case :^)

this, i thought i misclicked on Sup Forums

Why do you declare yourself as bits (nibbles) to be overwritten ITT?
//
你為什麼要聲明自己是位(半字節)將被覆蓋ITT?

why isnt this working

return True

Are you trolling?

#64566194
this wasn't funny the first four times

I think he's trying to write a polyglot

Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 20:19:30) [MSC v.1500 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
>>>
========================= RESTART: Z:\Desktop\HW.py =========================
Hello world
>>>

c++ is the greatest language of all time

>no replies
D-does this mean I win?

>github
you're the biggest loser desu

>>>print("Hello world")

ty for trying, i still get error

Query ? Language?

C, C#, C+, C++, Java, COBOL?

how is this fizzbuzz?

No python. I think 2.7

COBOL金融交易

Re:request> Parser error.

The image OCR, syntax incept.

C++ language detected.

#include
using namespace std;

int main()
{
cout

Well that's debateable, since thanks to it have six $150k+ job offers despite no CS degree and the company I sign with being my first non-retail job. :^)

Sorry I don't understand

do I Just need to add using namespace std? I thought if it was using print I didn't need to define a namespace

it's not.

What is your query? The script I provided is accurate.

C++ does not need to import a "Helloworld.py" file to function.

FIZZBUZZ: perl -E 'say "Fizz"x!($_%3)."Buzz"x!($_%5)||$_,"\n" for 1..100'

It is a chinksbot. He even can OCR, and google shit.
I guess we have to replace google captcha, with normal captcha

what is it then?

I'm trying to hello world in python. help please

print("hello world")
try this, but I don't really remember pyhton.
And int main() bla-bla is not needed as I remember.

main = putStrLn "Hello, World!"

C:\Users\James\Desktop\helloworld.py

string = 'Hello world'
print(string)

Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 20:19:30) [MSC v.1500 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
>>>
========================= RESTART: C:\Users\James\Desktop\helloworld.py =========================
Hello world
>>>

So, like a fishing net?

What is on that picture?

>Algebra(including Linear Algebra)
>Discrete Math
>Calculus
In which order should I learn these Math subjects, in other to become a better computer scientist? Also, which topics in said subjects should I focus on, in other words, which sections on said subjects are the most important for Computer Science. Thanks in advance.

I'm Not Ded (Granny Weatherwax, if only humans would read books instead of bleeding all over them)

I'm Not Bot.

I'll just assume you guys still think I'm a robot, even though that literally makes no sense.

Does Sup Forums require psychiatric aid?

請問/ GA /需要精神科的助手?

use ACME::Eyedrops; use feature qw (say); say "Fizz"x!($_%3)."Buzz"x!($_%5)||$_,"\n" for 1..100;

what

I've given up on python.

How do I make a 3d engine in C++ that renders in openCL?

I apologize, I thought you were asking me to be your friend.

Shall I re-initialize?

>Algebra
>Calculus
>Linear Algebra
>Vector Calculus
>Discrete Math

我已經放棄了蟒蛇。

如何使在C ++呈現OpenCL中的一個3D引擎?

Why do you want to rewrite OpenGL and Unreal Engine?

Patrician approved

>I've given up on python.
sweeter words never spoken were

Thanks for the reply. Any reason why Discrete Math at the end? I thought it would be essential to learn before calculus, or something.

After a brief hiatus, I think I'm done working on my little interpreter altogether. As some user suggested, I added a type checking pass that catches almost everything except missing returns in branches. Type generics work, although they are not accessible to the user (user cannot declare generic classes), closures work, first class functions work. Obviously, arrays work. My friend managed to implement a prime generator using it.

Now that I'm done, I need ideas for another project. I have a few of my own, but none of them seem appealing at the moment. What could be something I can work on now?

Learn Agda first.

What the fuck is going on

too much systemd

nani?

You are learning 'Simon Basal Descriptor Logic'

你學的“西蒙基礎描述符邏輯”

yлyчшaй aнглийcкий

The best english is 'my' english. If you have a problem with that you can take it up with Stephen Hawking and Stephen Fry.

лyчший aнглийcкий

Russians really do rush headfirst into stupidity.

Again, just so Russia understands this, I tried to give your country the Riemann-Zeta proof and your FEMALE MATHEMATICIAN housed at RMIT UNIVERSITY, MELBOURNE, told me that I was 'wasting her time'.

So, if Russia wants to blame someone, go blame her.

I was nice.

Has Googles new captcha been broken already?

Discrete math has absolutly nothing to do with calculus. In fact, they're practically opposites.

Can you update your codebase so you respond more like HK-47?

nah, I think it's just a /sci/ cross-boarder with some next level shitposting.

I like it.

Yes, I could. "Can" is a different matter altogether.

是的,我可以。 “能”是完全不同的事情。

Google's CAPTCHA is limited for human-friendly interpretation, meaning there will never be a rape or any Sup Forums style images on it.

It is presented as a 4x4 grid with a simple keyword and will always be from the perspective of 'safety vs occlusion'.

Facial Figure recognition online.
//
谷歌的CAPTCHA是有限的人性化解讀,這意味著永遠不會成為強姦或它的任何/ B /風格的圖像。

它是作為一個簡單的關鍵字4x4網格,將永遠是從“安全VS閉塞”的觀點。

面部識別圖在網上。

Can we give the spambot a cute girl name and adopt it as our daughteru already?