[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

/dpt/ - Daily Programming Thread

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 337
Thread images: 37

File: vim pls.png (125KB, 689x920px) Image search: [Google]
vim pls.png
125KB, 689x920px
Previous thread: >>57451610

Whatcha workin' on, /g/?
>>
File: indians.png (5KB, 235x117px) Image search: [Google]
indians.png
5KB, 235x117px
>>57470763
Creating a program that analyzes a database and recreates the schema with no constraints on another SQL Server.

So far it's working with MySQL and other SQL Servers.

Will add support for basic JSON-based APIs and other relational databases soon.

Should be useful for data staging when building the data warehouse and other integrations.
>>
Haven't coded anything since I got my diploma and have no ideas or inspiration. I feel like I need to get into it and work towards freelance because even though I've been flinging resume's for months I've gotten nothing but a brief interview at a pet-food canning place [spoiler]Which I lost out on to someone younger[/spoiler]. What do?
>>
>>57470892
Hello, newfriend.

You cannot spoiler on /g/.

I also have a strong hatred for anyone who uses the phrase "What do?".

In any case, you want to start with the most job-saturated languages and learn them enough so that you can actually create small programs that do things.

Pick either Java or C#. Alternatively, the next bracket of open jobs is about the same between C, C++, and Python.

It would also help to learn Javascript, and you should understand basic SQL.

If you can create a small application from start to finish that talks to a database or API, massages that data to show good info, and displays that information on a GUI of some sort, you're definitely hireable.
>>
#include <stdio.h>
int main() {
int a, b;
b = 20;
a = b;
printf("%d", a); // 20
{
b++;
int a = b;
printf("%d", a); // 21
}
printf("%d", a); // 20
}

triggered
>>
>>57470992
>not using code tag
>not understanding scope
>
>>
>>57470935
I forget which boards do and don't. I'm already familiar with C# and java, looking to get into C++ as well because of efficiency memes.
I can make an application with all that shit but I haven't any ideas as to what to make it for.
>>
Need to make and host webpage.
I know lamp, I'm maintaining old php code at my work.
I thought I could do this with some "modern" tooling so the question is which stack should I choose?

I thought I could use:
java, jetty, spark - jetty can be changed but the performance of the server really doesn't matter in this case
python, nginx, flask
something else what?
>>
So I took a few basic CS classes and did some time on codecademy and hackerrank. Figuring out small problems on a cmd or IDE output window is all well and good, but where do I start learning how to make a full fledged program, complete with its own executable binary, gui, and maybe some professional level revision control and the like? All the textbooks I've read so far have just gone into the basics, and the closest I've come is some wonky Java applets and drag-and-drop C#.
>>
>>57470992
Why is it allowing you to declare int a twice in the same scope?
>>
>>57471336
Is not the same scope.
>>
>>57470763
Im currently working on a realtime steganography service that hides inside facebook and twitter and writes steganograms in form from lolkitten pics. In the first phase you can request webpages that are fingerprint free rendered with a headless web engine. You are completely anonymous and Google/Apple/Nasa have no clue what you are watching.
>>
>>57471483
Are you a terrorist?
>>
>>57471483
i will follow this thread for this
>>
Is codeacademy a good way to learn Java?
>>
holy shit guys, is it bad that everytime i code in an OOP language, I go crazy with making objects, inheritance, and interfaces.

I feel like i over engineering my solution.
>>
>>57471598
OOP isn't really engineering.
You can think of OOP as being like modern art.
>>
>>57471592
No.
>>
>>57471592
The only thing codeacademy is good for is to learn syntax. everything else is mostly monkey see monkey do shit. you dont learn anything.
>>
>>57471607
ok maybe engineering inst the right word, but you get what I'm saying.

I see this as a bad habit, but im still a noob.
would really like to hear /dpt/ opinions
>>
I am writing a JavaFX application. I have a window that contains a button, and when I press that button, a new window opens. I can not open more than one window using the button, which is what I want. So far so good.

Then I close the new window, and then press the button once more. The old instance of the new window appears.

What's the best practice for making new windows for every button press, while maintaining the "max 1 window at a time" requirement? Do I create a new stage for each window? A new scene? A new pane?

Thanks for any help/tips.
>>
>>57471789
When you create the subwindow you need to create new scene and then in the new window use setScene? I think but I might wrong
>>
>>57471645
>would really like to hear /dpt/ opinions
Hopefully with about 19 grains of salt.

If what you're doing saves time and makes the code easier to maintain, great!

If it's consuming lots of time with little to no benefit, then that's not great.

It's just another technique, and every common technique exists to solve some sort of problem and make your life easier. If you're abusing the technique in such a way that you're getting net negative benefit, then you're likely using it wrong and in the wrong place.
>>
>>57471592

This: >>57471609 >>57471611

This also goes for any of the other websites or apps. The best way to learn java is either through classes with a good instructor (or if you find tutorials online by people who actually know how stuff really works), or by picking up a book.
>>
>>57471810
I do that stuff mainly because it helps me structure my program. But i feel like I spend too much time on it.

my thought process is, I'm future proofing my program. But i dont know.

> Hopefully with about 19 grains of salt.
also I thought everyone were stem phd
>>
What's a good online resource for learning Haskell?
>>
;^)

int x = 0;
x = x++;
return x;
>>
>>57471924
LYAH but some of it is out of date
>>
>>57471941
int x = 0;
return (x = x ++);
>>
>>57471958
return 1;
>>
File: perl6.png (17KB, 250x183px) Image search: [Google]
perl6.png
17KB, 250x183px
Anyone else learning Perl 6? I really love it, especially the gradual typing system.

>>57471924
http://learnyouahaskell.com/chapters
https://lotz84.github.io/haskellbyexample/
>>
>https://alexnisnevich.github.io/untrusted/
>>
>>57472045
Pretty cool, I'm on level 5.
>>
>>57472091
>>https://alexnisnevich.github.io/untrusted/
>>>
> Anonymous 11/11/16(Fri)11:37:21 No.57472091 â–¶
>>>57472045
>Pretty cool, I'm on level 5.

cool was this made using React.js?
>>
>>57471483
>steganography
I wonder how many pedo images are hidden in the open like this
>>
>>57471607
>abstract art
>>
>>57471950
>>57471988
Learn You a Haskell looks good. Thanks.
>>
File: DSC_3317-ax-red.jpg (126KB, 1000x715px) Image search: [Google]
DSC_3317-ax-red.jpg
126KB, 1000x715px
Question for /dpt/:

I've been reading The Linux Programming Interface (pic related) and think it's the best programming book I've ever read. Now I want to use syscalls everywhere I can. Is there ever any reason to use a Linux syscall over a standard library function if I know my application will only be run on Linux?
>>
I'm learning how to create libavfilter (ffmpeg) filters.
>>57472339
Higher-level calls, are, well, higher-level, more convenient.
>>
>>57472206
No, modern art
>>
>>57471851
If you don't know for sure that the abstraction is going to help you later, don't do it. Also, the thing about OOP is that it often involves things like inheritance that can actually lead to even more wasted time down the line because you've set up a brittle abstraction that doesn't work with a change you want to make.

It's the exact same problem as premature optimization (you can think of it as optimizing for the least duplication, even). Don't optimize when you don't know that it will provide a significant performance gain.
>>
I've read how
using namespace std

can be bad practice.

But does the more explicit
using std::cout

have the same pitfalls?
>>
>>57472904
Both are bad at the top level of a header file. Otherwise both are fine.
>>
File: image.png (61KB, 1680x1050px) Image search: [Google]
image.png
61KB, 1680x1050px
>>57470763
>Whatcha workin' on, /g/?
a RPN calculator for r/dailyprogrammer #291 Intermediate

>>57470763
Please use an anime image next time.
>>
Please recommend some MOOCs or some other resource that'll help me git good with C# and Scala.

I'm not really a beginner programmer, but most of my experience lately has been in Python, and I don't have any experience doing real functional programming. I'm also kinda rusty when it comes to OOP with statically typed languages.
>>
>>57471988
>http://learnyouahaskell.com/chapters

Perl 6 learner here. I love it, although I'm a non-programming amateur and haven't really used Perl 5 before.
>>
>>57472939
>Please use an anime image next time.
OP here.

Please provide a zip of images, and I will next time. I didn't have any programming-related anime on my work laptop.
>>
>>57472959
thats on you to find anon, download the /dpt/ one next time and use it
>>
>>57472904
Namespaces were invented to solve the issue of name collision in different parts of code (often developed by different parties). Using declaration kind of defeats this purpose.
You should probably never use the general version but you can use the specific version if you use some name often, and can be reasonable sure it won't clash with your own names.
>>
>>57472972
Well then I'll damn well use whatever image I want, since we're both so lazy.
>>
>>57471293
>Java applets

disgusting.

But seriously, I recommend you work on web apps. Learn HTML, CSS, JavaScript, and some front-end framework (React or Angular).

You can also do stuff with Python + Django (or Flask), but that would require knowledge of CSS and HTML too if you wanna make something that looks good.

I've never used Ruby on Rails or anything else. Well, I did use C++ and Qt on a desktop application, and I remember it was pretty good.
>>
File: 1443500977688.png (835KB, 1200x1080px) Image search: [Google]
1443500977688.png
835KB, 1200x1080px
>>57472959
>>
>>57472339
compare what you can do with printf and with write.

library functions are safer (more safety checks), well tested (more than your homemade ones) and more convenient.

In the end you will probalby write half of the stdlib yourself to ease your usage of syscalls, just your version will be worse.
>>
how do you use the scanner class in java to call constructors using user input?
>>
>>57472987
Since it was your responsibility it's your laziness and failure, sorry.
>>
>>57473003
are you a good programmer anon? ;o
>>
File: girls(boys).jpg (23KB, 311x202px) Image search: [Google]
girls(boys).jpg
23KB, 311x202px
>>57473003
>>
>>57472939
learn to redirect data m9. cat is deprecated
>>
im creating a hash table with a linked list that has to deal with collisions and I was wondering if it would be weird for my node to have a an "int" variable called value that would serve 2 different purposes depending on the situation. For example if there is no collision this "int" variable becomes whatever number the hashing algorithm gives me (and I put that node at that position). If there is a collision i create a new instance of the linkedlist and this value will now just start at 1 get ++ everytime a new collision happens at that position.

Is there a better way of doing this? I was thinking making two different variables but creating the printlist function would become awkward
>>
File: 2016-11-11-192117_778x42_scrot.png (3KB, 778x42px) Image search: [Google]
2016-11-11-192117_778x42_scrot.png
3KB, 778x42px
>>57473169
>>
>>57473196
oh im laffin'
>>
>>57473183
The way I always implement mine is by saving the key in the linked list node. That way even if the hash is the same, it then compares the key that's used to retrieve data with each node. Makes sure collisions don't fuck up my data. Probably isn't too efficient though.
>>
>>57472939
How do you get that nice scanline effect in your editor?
>>
File: ocaml.png (58KB, 420x420px) Image search: [Google]
ocaml.png
58KB, 420x420px
What does /g/ think of OCaml?
>>
>>57473346
I haven't had a reason to use it. Ever.
>>
>>57473196
>>57472939

wtf is wrong with you? why are you using this shit font?
>>
>>57473346
Worst language ever, use Haskell
>>
>>57473360

It's the default functional language in my uni... like, what has Haskell done to you?!
>>
>>57473328
so when you're searching for the data by let's say the persons name or whatever you just run the persons name through the hash algorithm and then loop through the linkedlist until you find that value?
>>
>>57473382
>implying I use Haskell

No reason for me to use that, either.
>>
>>57473345
>>57473361
http://asdasd.rpg.fi/~svo/glasstty/
http://fontstruct.com/fontstructions/show/760131/twotwenty
>>
>>57473328
Yeah, I find the linked list at the hashed index and then strcmp each node's key until it matches
>>
>>57473418
Oops. Meant to quote
>>57473392

Mobile posting sucks
>>
>>57470763
I'm working on a demo for my team.

Found a possible zero-day exploit at my company with the anti-virus service we have, reported it but it won't be fixed in a long while due to the nature of the bug.

The team wants to see it demonstrated and im currently trying to privilege escalate with it.
>>
>>57473399
Doesn't work for me sadly. Says to set to size 15 on windows but ends up looking weird. Thanks for the link anyway.
>>
>>57473399
what's the point of doing this? It hurts my eyes and doesn't look good at all
>>
>>57473506
>>57473547
try size 24
try to disable anti aliasing
>>
>>57472939
Also what DE/window manager is that?

>>57473547
idk, I think it's comfy as fuck
>>
>>57473588
https://awesome.naquadah.org/
>>
>>57473619
cheers boi
>>
>>57473382
what uni?
>>
>>57471592
no, codeacademy isn't a good way to learn anything
>>
>>57473382
it made me to intellectual to use any other language but haskell
>>
File: 1466404167337.jpg (828KB, 2448x3129px) Image search: [Google]
1466404167337.jpg
828KB, 2448x3129px
>emailed my prof a question
>found the answer 2 mins later

haha
>>
is there any way to have math symbols and formulas in an IDE? I work with a lot of math so I want to use mathematical notation in comments/
>>
>>57473787
ligatures?
>>
>>57473787
Visual Studio supports unicode
>>
>>57473803
ligatures cant do summation, underscore, powers etc.
>>
kind of annoyed when i found out the brainlets in my programming languages classes have all been getting one guy to complete the assignments and then having him give it to 15 other people and they all change it slightly and submit it
>>57473781
he will think you're a fool
>>
>>57473821
> implying professors dont think all their students are idiots
>>
In c++ is there any way to find the numeric position of a pointer? For example if I create a pointer called ptr and assign it an array, then do ptr+=10; I can find the address of the pointer with ptr, I can find the value it is pointing to with *ptr, but how do I find out that I have added 10 to the pointer?
>>
>>57473839
>implying all students aren't idiots
>>
>>57473861
true af
>>
>>57473781
This is why rubber duck debugging is a thing.
>>
>>57473815
that sucks, i dont use vs.

intellij master race~
>>
>>57473882
> that realization when I will never make real friends so I will always have to carry around a rubber duck.
>>
>>57473915
You can just talk to yourself or pretend you're talking to someone, you don't actually need a rubber duck.
>>
>>57473955
> talk to myself
I can't even talk to a rubber duck?? FML
why even live.

i bet the world will be happy if i kill myself
>>
File: IMG_20161111_131019.jpg (305KB, 1303x975px) Image search: [Google]
IMG_20161111_131019.jpg
305KB, 1303x975px
>>57473915
>friends
Use co-workers.

I actually keep a meerkat at my desk for this reason, too.
>>
>>57473857
ptr - arr
>>
File: 20161111_141510.jpg (3MB, 5312x2988px) Image search: [Google]
20161111_141510.jpg
3MB, 5312x2988px
>>57473999
> co-workers
im still in college
>>
>>57474081
wat
>>
>>57473999
very cute meerkat
>>
>>57474115
You have the initial address of the array as a pointer arr.
>>
>tfw have to learn java in school
why
>>
>>57474151
should be a war crime 2bh
>>
>>57474151
its your part of your heritage Pajeet.
>>
>>57474151
i had to learn visual basic last year
>>
>>57474205
>Dim a As Integer = 1
>>
>>57474082
Australia has colleges?
>>
>>57473346
I would be using ocaml but...
It's has GIL which means only one thread can execute at time.
They are working on it https://github.com/ocamllabs/ocaml-multicore
But the state of it seems uncertain.
>>
>>57474151
>>57474205
My course has us mostly making windows forms with visual basic in visual studio and making websites out of php. At least I'll be Microsoft Certified :).
>>
anyone gay?
>>
>>57474247
I had to learn it too last year, fortunately I will never use this shit language ever again
>>
>>57474438
>Microsoft Certified
The MCSD uses C#, doesn't it?

I don't think there are any certification beyond the useless MTA that you could get only knowing VB.
>>
>>57474439
yeah, you
>>
>>57474515
wtf
>>
I work at a law firm and want to create an application where we put in our new case and it predicts the result based on the factors we know on Day 1.

Would I use machine learning for this? I've never done that before but I feel like I would.
>>
>>57474584
Haha, you would have to feed your AI with a lot of past cases so that it can learn from them because there is much more than the facts to take into consideration.
This would be pretty hard to make
>>
I occasionally see property setters that look like this:

def x= (new_x)
if @x != new_x then
@x = new_x
end
end


Is this any faster than just assigning without checking first?
>>
>>57474604
We currently use a database to track our cases. We've been using it since 2012 and have about 8,000 cases in it. I can export any of the fields I want in a query so producing the data shouldn't be super hard. Is 8,000 not enough?
>>
>>57474612
If the type of x is a fucking huge class with hundreds of big variables yeah
if x is an int it's useless
>>
>>57474612
No. In fact it will always be slower unless there is some pathological situation where comparison is faster than assignment.
>>
>>57474612
What language is that?
>>
>>57474638
8000 is a pretty small set when you consider all the possible lawsuits
But you still need to make you AI and a neural network or whatever isn't a magic tool, you still need to tell it how to learn stuff
>>
>>57474664
maybe ruby
>>
>>57474664
Ruby.
>>
Anybody have a better method of generating pi with python3?

from decimal import *
getcontext().prec = 15000
pi = Decimal(3.0)
acc = 10000

pi = sum(1/Decimal(16)**k *
(Decimal(4)/(8*k+1) -
Decimal(2)/(8*k+4) -
Decimal(1)/(8*k+5) -
Decimal(1)/(8*k+6)) for k in range(acc))

f = open('piDigits.txt','w')
s = str(pi)
f.write(s)
f.close()
>>
Honestly nothing because im a lazyfag
>>
Just starting to into python. Any help on why this won't run?
numbers = [5, 35, -20, -35, 40, 850]
maximum = numbers[0]
minimum = numbers[0]
i = 0
for i in numbers:
if numbers[i] > maximum:
maximum = numbers[i]
if numbers[i] < minimum:
minimum = numbers[i]
print "max: %d, min: %d" %(maximum, minimum)
i += 1
>>
>>57474752
I don't think that's how for in works
>>
>>57474752
numbers = [5, 35, -20, -35, 40, 850]
maximum = numbers[0]
minimum = numbers[0]

for i in numbers:
if i > maximum:
maximum = i
if i < minimum:
minimum = i
print "max: %d, min: %d" %(maximum, minimum)
>>
>>57474715
from math import pi
>>
>>57474715
https://pybenchmarks.org/u64q/program.php?test=pidigits&lang=python3&id=4
https://pybenchmarks.org/u64q/program.php?test=pidigits&lang=python3&id=2
>>
Got an animation state machine in Unity, I'm deciding to use a single integer State variable to cause transitions. Is this a bit against the spirit of state machines and sheit? I mean before I was using tons of variables to cause the switches but now I'm trying to put the logic for changing state in the StateMachineBehaviour scripts...
>>
>>57474781
Thanks
>>
>>57474812
oh wow, thanks a lot /s
>>
>>57474833
> /s
>>>reddit
>>
>>57474752
>>57474781
>>57474823

if you wanted to iterate over indices of the list, you could use enumerate:

numbers = [5, 35, -20, -35, 40, 850]
maximum = numbers[0]
minimum = numbers[0]
i = 0
for i in enumerate(numbers):
if numbers[i] > maximum:
maximum = numbers[i]
if numbers[i] < minimum:
minimum = numbers[i]
print "max: %d, min: %d" %(maximum, minimum)
i += 1
>>
File: 1478422340984.jpg (18KB, 240x200px) Image search: [Google]
1478422340984.jpg
18KB, 240x200px
tell me how shit my program is
>>
>>57474821
A good way to do a state machine with OOP is to have an interface with implementors for each concrete state like so:
interface State {
void update(); // or whatever
State next();
}

Transitions are done by returning a new state from "next". Return "this" whenever you don't want to transition.
>>
>>57474852
https://github.com/jamms69/Asvab-Calulator

forgot link
>>
>>57474752
>>57474781
>>57474823
>>57474850

Whoops i meant:

numbers = [5, 35, -20, -35, 40, 850]
maximum = numbers[0]
minimum = numbers[0]
i = 0
for i, elem in enumerate(numbers):
if numbers[i] > maximum:
maximum = numbers[i]
if numbers[i] < minimum:
minimum = numbers[i]
print "max: %d, min: %d" %(maximum, minimum)
i += 1
>>
>>57474854
Oh, and the "state machine" just becomes:
State state = new InitialState(); // or whatever
while(isRunning) {
state.update(); // or whatever
state = state.next();
}
>>
>>57474877
while(state)
>>
>>57474854
>>57474877

Why not just:

interface State {
State update(); // or whatever
}

State state = new InitialState(); // or whatever
while(state) {
state = state.update(); // or whatever
}
>>
>>57474854
Ah OK nice. I think that matches what I'm trying with Unity. So the next state is chosen in state code and not worked out "outside" using multiple conditions.
>>
Yesterday someone asked about how to check palindromes from a list of words in python.
People were saying to use a reverse map or hash table. How would you make a hash function with words? Shouldn't it be something like
while(i = 0; i< normalword.length; i++)
if
normalword[i] == reversedword[i]
print(normalword)

If you wanted to check for palindromes in a list? Is i = i the hash function if you were to make a hash table?
>>
>>57474869
Don't they already calculate your percentage for you?
>>
>>57474833
from math import acos

print(acos(-1))
>>
File: 1373662916812.jpg (171KB, 600x400px) Image search: [Google]
1373662916812.jpg
171KB, 600x400px
>>57474852
>>57474869
>No license.

Please use the gplv3 license, the only license endorsed by Richard M Stallman (PhD).
>>
>>57474900
Sure, you can do that. How you split up the behaviour into methods depends on if and how you want to use inheritance.
>>
>>57474492
to be fair, if you're not literally braindead, you can jump from Visual Basic to C# with WinForms with nearly no effort

it's really fucking easy and very familiar
>>
>>57474965
>using GPL, the anti-freedom license

No, thanks.
>>
>>57474949
my program calculates linescores which are used to find what jobs you are qualified for in military based on your scores
>>
>>57474976
Certifications don't use WinForms anymore, either, and XAML-based GUI is a whole 'nother animal.
>>
>>57474965
PhD in communism maybe
GPL is stalinist propaganda
>>
File: corruption.png (45KB, 556x1011px) Image search: [Google]
corruption.png
45KB, 556x1011px
>>57470763
>highlight lines and tab
>Pic related
aaaahhhhhhhhh!
>>
>>57474869
It's literally hello world tier, but well done anyway
>>
>>57474869
>adding AR and MK together multiple times

0/10, DRY faggot
>>
>>57475002
>tier
That's not how you use that word
>>
>>57473915
>tfw you have no gf so you carry around a proprietary material life-like vagina-shaped onahole
>>
>>57475025
Checks out in relation to 4chan-speak.

You can say something is shit tier, or babby's-first-program tier, or even haskell-but-not-haskell tier.

Are you relatively new to 4chan? I'm genuinely curious.
>>
>>57474985
Alright. If I remembered my scores I'd try it.
>>
>>57475045
>Checks out in relation to 4chan-speak.
No, it "checks out in relation to reddit-speak".
It started a few months ago, and the newfags (YOU) lapped it up
>>
>>57475089
>It started a few months ago

I beg to differ.
>>
>>57475089
You are wrong, friend.

I've been here since around 2006, whenever Snacks was running rampant and Cracky-chan was slutting it up.

"tier-list" images have been common on 4chan for a very very long time, and typically include a comical 'tier' that is specific, rather than saying things are "god", "great", "shit", etc.
>>
>>57475089
shit tier has existing for ages you massive faggot
>>
>>57475102
>>57475114
>>57475120
usage accelerated massively in the past 6 months or so
>>
>>57475131
>not only backpedalling, but making a drive-by statement that is can't be proven or even discussed

It's okay to just say "I was wrong" from time to time.

Hell, you could have even left it at that and not posted about it any further.

Instead, it turns out you're even more of a faggot.
>>
>>57475299
inb4hahayoumadeatypo
>>
>>57475299
>backpedalling
So now you have to explicitly say that or else people will think IT NEVER EXISTED AND NOBODY EVER USED IT AT ALL DEFINITELY before then?
>>
>>57475342
The fuck do you think "started" means?

Maybe it "started" 6 months ago reddit, but it "started" many years ago here.

On top of that, you're in a programming thread.

We spend every day talking to machines who deal in absolutes, and do exactly what is explicitly said to them.

Knowing your audience is an important part of communication, and communication is NOT what you say; it's what your audience interprets from your communication.

Your favorite programming language is probably shit, too, nerd.
>>
>>57475385
The OUTBREAK started
>>
File: out.webm (381KB, 1200x800px) Image search: [Google]
out.webm
381KB, 1200x800px
r8
>>
>>57475450
10 minutes in Box2D/10
>>
>>57475406
You never used "outbreak" before.

Are we supposed to just assume words that entirely change the meaning of your sentence?

>>57475450
1/10, would not keep me entertained for long at all. Needs color.
>>
>>57475450
good/10
>>
>>57475470
No, you're supposed to use your brain to infer the context, for instance:

>>The wolves started coming a few months ago
>Wolves have been around for thousands of years
>>
File: out.webm (296KB, 1200x800px) Image search: [Google]
out.webm
296KB, 1200x800px
>>57475465
fug you got me

>>57475470
here ya go
>>
File: 1424571701728.jpg (19KB, 500x500px) Image search: [Google]
1424571701728.jpg
19KB, 500x500px
>libraries that use global state
>>
File: 1452474855191.jpg (8KB, 316x202px) Image search: [Google]
1452474855191.jpg
8KB, 316x202px
>>57475603
>libraries that use global state and don't at the very least have reference counting for init/deinit
>>
Did anyone here ever do ars digita's SICP? Can anyone vouch for it's quality?
>>
>>57474584
The hard part of this imo would be translating the factors you know on day 1 to something your computer can understand and fits neatly into samey inputs.

Machine learning is a decent approach if you give it a push in the right direction at the start
>>
>>57474584
i dont know about law and what factors into your decision making there. but I can assure you, no machine learned algorithm will provide commercially reliable answers if more than half of the parameters are human. if such an algorithm could be created it would take millions of cases to build it, and it would be all for nothing every time a major event happens to your parameters (say if the judge is a major factor, and you know theres 5 judges you usually deal with, one dies and one gets married and your algorithm's accuracy is basically reset to zero)
>>
https://developers.google.com/maps/documentation/javascript/examples/layer-transit

Been playing around with this example but when I move the map it doesn't show transit information for the rest of UK. It only shows London. Does anyone know why?
>>
program found a pastebin with someones ftp login credentials, do what you please
http://pastebin.com/ifMhUcwi
>>
>>57470763
anyone who doesn't learn Go is idiot
>>
I just got out of an interview where they asked me what would you do if a customer said your software ran slow. I said I'd check my loops and for redundancy. What should I have answered?
>>
>>57471941
int x;
return ((x = 0) = ++x);
>>
>>57476172

Wrong. You first ask for more specific information as you can about if the software as a whole is slow or only portions of it. Then, you PROFILE the software to make sure you can reproduce the slowness or metrics.

And then you do what you said,
>>
>>57476197
Fuck me I thought about that after I was walking to my car. I was just too nervous which made me rush. They asked what kind of joins there were too and I fucking forgot to say self join.
>>
>>57476172
you were supposed to insult the customer
>>
>>57476176
>(x = 0)
That does not return an lvalue.
>>
>>57476251
> That does not return an lvalue.
but muh commpile does. what do?
>>
>>57476139
(you)
>>
File: 1371866934141.jpg (28KB, 251x205px) Image search: [Google]
1371866934141.jpg
28KB, 251x205px
>There is a house
>Any number of animals can enter it at any time
>only 1 human can enter it at the time
>human can only enter when at least 3 animals are in the house
>at least 3 animals must remain in the house while human in it

>write a pseudo-code to solve this problem using semaphores and variables

Help this is melting my head down
>>
>>57476410
Humans are animals.
>>
>>57476454
OK replace animal with e.g. dogs then
>>
>>57476172
Creating a performance model using the tool i work on check if there are any performance bugs.
If there arent any, tell the customer to fuck off
>>
File: 1476967871565.png (248KB, 340x523px) Image search: [Google]
1476967871565.png
248KB, 340x523px
so I have this the code inside my dll
#pragma data_seg("SHARED")
std::wstring filePath = L"";
bool endThread = false;
#pragma data_seg()
#pragma comment(linker, "/section:SHARED,RWS")

afaik it should allow me to share the variables between processes
but when one of the processes modifies the filePath the other can't access it, is that supposed to happen? I need to make it not happen
>>
>>57470763
Learning Qt, so far i'm pleasantly surprised.
>>
>>57476410
>import solution
>solution()
>>
>>57476410
When a human arrives, it has to wait until there are at least 3 animals but also no human.
When an animal leaves and there are only 3 left, it has to wait until there is no human.
>>
>>57476491
Sharing C++ classes that way is probably not gonna work (it definitely doesn't work for any class with virtual functions, since function pointers can't really be shared, and any std:: class may well have either virtual and/or function pointers inside them).
You also have the problem of constructors being called, filePath will get set to L"" every time a process loads the dll.

The official recommendation is never share C++ classes across process boundaries, only POD types.
>>
Would putting an array definition in an if, else statement fuck up a C compile?
int main(void)
{
int day, month, year;

day = 8;
month = 10;
year = 2016;

int dateArr[3] = {day, month, year};

printf("The current date is: ");

int i;
for(i = 0; i < 3; i++)
{
if(dateArr[i] < 10)
{
printf("0%i", dateArr[i]);
}
else
{
printf("%i", dateArr[i]);
}

if(i < 2)
{
printf(".");
}
}
printf("\n");
return(EXIT_SUCCESS);
}


If keeps saying that my later use of dateArr is undeclared.
>>
>>57476672
Wrong code snippet

    if(murrican)
{
int dateArr[3] = {month, day, year};
char sep = '/';
}
else
{
int dateArr[3] = {day, month, year};
char sep = '.';
}
>>
File: paheed.png (240KB, 852x1836px) Image search: [Google]
paheed.png
240KB, 852x1836px
Does anyone want to help me with this?
https://hackerrank-challenge-pdfs.s3.amazonaws.com/12860-kindergarten-adventures-English?AWSAccessKeyId=AKIAJAMR4KJHHUS76CYQ&Expires=1478907861&Signature=G5dYXf2EgWt7fXSrSl4qVZu86ec%3D&response-content-disposition=inline%3B%20filename%3Dkindergarten-adventures-English.pdf&response-content-type=application%2Fpdf

function processData(input) {
input = input.split("\n");
var n = Number(input[0]); //Number of times
var arr = input[1].split(" ").map(Number); // array with times
var upLimit = n;
var currentID = 1;

for(var i = 0; i < n; i++){
var failures = countFailures(arr, upLimit, n, i);
if(failures < upLimit){
upLimit = failures;
currentID = i + 1;
}
if(upLimit == 0) break;
}

console.log(currentID);

function countFailures(arr, upLimit, n, j){
var failures = 0;
for(var i = 0; i < n; i++){
var k = ((j + i) < n) ? (j + i) : ((j + i) - n);
if (!(arr[k] <= i)) failures++;
if (failures == upLimit) break;
}
return failures;
}
}


The code runs and is able to solve some test cases correctly, however it times out with most test cases.
Any idea how can I make it more efficient?
>>
even with wwonky copy paste vim is still the best code editor.

Everytime I have visual studio open for more then a day or so the clipboard stops working completely, which is worse than having to deal with vim.
>>
>>57476691
Outside of your if/else statement dateArr does not exist
also,
>declaring the array in two different way depending on the user, not just printing it differently
>>
>>57476691

Do this:

    int dateArr[3];

//...

if(murrican)
{
dateArr = {month, day, year};
char sep = '/';
}
else
{
dateArr = {day, month, year};
char sep = '.';
}
>>
File: embarcadero-delphi.png (43KB, 267x282px) Image search: [Google]
embarcadero-delphi.png
43KB, 267x282px
What does /g/ think of Delphi?

I work for an IT company and already maintain various projects in php, java, vba, C# .NET and js (various frameworks).

Last month we had taken on supporting a Delphi project and it's more or less my first time with Delphi/Pascal.

I'm enjoying it so far, from a RAD standpoint it is even faster to work with than .NET (and yet is easily cross-platformable); everything you need is already included in standard libraries.

For example - appending to a text file whether it already exists or not takes literally one line with standard IO utils, reading/writing to ini files is piss easy, socket programming and database handling done with just a few components, etc.

If I was going to make someone software for their business from scratch, I'd probably use this - assuming I could absolve the developer licensing costs in there somewhere.
>>
Can you suggest a comfy c++ code editor for linux, for a winfag coming form Visual Studio and needing to do some work on linux?
>>
>>57476580
thank you my dude

but how do I share string? I tried to replace
 wchar_t filePath[MAX_PATH] = L""; [\code] but it says wchar_t[260]is not assignable,
>>
>>57476847
emacs
>>
What's a good book for getting better with RDBMS? I'm strong on the basics (I work as a more or less 'full-stack' developer but I always use ORMs and I feel like SQL is a good language that I'd like to learn to get more out of, and learn how to express more complex structures with. I feel like I find myself tending towards wanting to do things with JSON fields too often in my design and pushing data validation into application logic too much.

Is there a canonical/good intermediate-advanced book for design and finer aspects of relational databases?
>>
File: 1456190202999.jpg (103KB, 964x964px) Image search: [Google]
1456190202999.jpg
103KB, 964x964px
>make a mistake somewhere
>can't figure out what it was
>whatever, I'll just undo my changes
>still doesn't work
>>
>>57476858
Really?
While i don't doubt that emacs is powerful and comfy in the right hands, i have gotten the impression that it is not for someone like me.
>>
>>57476784
It's a crime that it's not more popular imo
>>
>>57476886
>not for someone like me
>like me
what are you? A retard?
Learn how to use emacs and you'll be more efficient at editing
>>
>>57476869
>(I work as a more or less 'full-stack' developer but I always use ORMs and I feel like SQL is a good language that I'd like to learn to get more out of, and learn how to express more complex structures with. I feel like I find myself tending towards wanting to do things with JSON fields too often in my design and pushing data validation into application logic too much.
Where does this parenthetical end you monster?
>>
>>57476884
git bissect
>>
>>57476886

I found emacs really easy to learn desu don't know what all the fuss is about. It's a great editor that has a strong plugin library that is still up to date and easy to use (repositories of plugins, tools to easily install them built in)
>>
>>57476730
You do realize that doesn't work?
>>
>>57476908
>winfag, visual studio
>what are you? A retard?
What do you think?

I'd spend a lot of time wrestling with emacs, instead of getting shit done.
>>
>>57476912
Yeah i fucked that up
>>
I wanna pick up a new high level language, which specifically is not important. Here's the trick though, I'm entirely confined to my smartphone. So what's the best ide on android?
>>
>>57476939
Termux+vim+clang
>>
>>57476939
Python.
>>
>>57476948
Which ide?
>>
>>57476921
>don't know what all the fuss is about.
Neither do i, never having worked with emacs. I've heard it's harder than vim, and from the little i've used that, vim is not comfy at all.
>>
>>57476962
Haven't tried but http://qpython.com/ looks good
>>
>>57476963

I found it simpler than vim personally. I feel like emacs operates more similarly to a standard modern text editor (sublime, atom, vscode etc.) than vim.
>>
alright lads, any of you have experience with matlab? you might be able to help me regardless but I had a question.
any way to check multiple columns to see if they share a matching value and return what the value is? Note that these columns are not the same size. I was thinking about using a bunch of loops to check for matches between elements and having it search the next column for the value until it fails but there must be an easier way right?
>>
File: Screenshot_20161111-161616~2.png (116KB, 1080x1857px) Image search: [Google]
Screenshot_20161111-161616~2.png
116KB, 1080x1857px
>>57476947
Patrician choice
>>
>>57476580
>>57476853
nevermind I'm actually retarded
>>
>>57473346
horrible syntax, and it tries to be imperative
use haskell instead
>>
>>57476710
I think you can do it in O(n) by taking partial sums
>>
>>57474752
in haskell, this is just
main = printf "max: %d, min: %d\n"
(maximum numbers :: Int) (minimum numbers :: Int)
where numbers = [5,35,-20,-35,40,850]
>>
>>57476939
kivy
>>
>>57474877
in haskell, this is just the State monad.
>>
>>57477030
ismember(A,B); where A and B are your matricies.

If you wanted something a bit more concrete, just look through here:
https://www.mathworks.com/help/matlab/ref/ismember.html


Also, what would someone recommend as a good programming language for a simple GUI file editor, where it parses a large file and allows the user to edit certain parts of it with buttons and such?
>>
File: 1459926416792.jpg (25KB, 263x263px) Image search: [Google]
1459926416792.jpg
25KB, 263x263px
>>57477208
>using the state monad for a state machine
>>
>>57470992
>triggered
why?
>>
>>57470992
It's kind of amazing that's allowed
>>
>>57476908
How does emacs let me be more efficient?
>>
>>57477241
I need to pull a single value from 4 matrices, and I know all 4 contain it. What would you recommend I do? Run ismember between two matrices and have a loop delete the elements with an index that returns 0? Then recheck and repeat against the other 2 matrices?
>>
File: EvenSigiliphIsDisappointed.png (182KB, 209x322px) Image search: [Google]
EvenSigiliphIsDisappointed.png
182KB, 209x322px
I have a quick python error.

So I downloaded a couple of libraries, "visa" and "pyvisa", and after restarting my computer, I ran IDLE, and when I ran
import visa
, it gives me the following error:

Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
import visa
ImportError: No module named visa


But I looked up the modules I've imported on the terminal shell (help("modules") after running python in the Terminal CLI), and I see both visa and pyvisa

When I run python from the terminal shell (not IDLE), importing the libraries works just fine... Any ideas as to what's going wrong?
>in b4 "using python"
>>
>>57477208
The "state" in "state monad" isn't the same "state" as in "state machine".
>>
>>57477334
by being the perfect tool for editing source code
>>
>>57477363
Thanks for the useless answer.
>>
>>57477341
>using IDLE

nigger just use a non-shitty editor and open a terminal and just type
python file.py
>>
>>57476847
If you're not doing anything large/corporate, vim/emacs are both very efficient. Takes a bit to learn at least vim, which is what I use, but only a few plugins and it's pretty good. Lack of functional auto complete so if it's for your job/you're doing something really large, you should probably go for a proper IDE so you can quickly jump around methods and namespaces.
>>
>>57477387
>so you can quickly jump around methods and namespaces
This is what i like about VS
>>
>>57476672
>>57476691
>>57476691
>>57476672
if you define your array inside an if/else, it will only exist within that scope.

Define it before the if statement, instantiate it/assign a value inside if/else
>>
>>57477408
Yeah, any good IDE has that. Vim has some level of functional auto complete and the ability to do so, but it's really, really slow and really buggy from my experience. However, the raw speed of text editing once you've learned vim is unmatched. Your hands get to stay right on the alphanumerical keys 99% of the time and you can record complex macros, substitute with full regex, repeat actions, meaning you could rename an extremely used namespace across every source file in seconds. I use ctrlp for vim as well which gives you quick fuzzy searching to open other source files, so you don't have to even take your hand off the keyboard to open another source file, and vim also has support for tabs like most IDEs do (of course, accessible by pressing a number and a key).

Project I'm working on at the moment would be about 7-9 files of code once done + extra makefiles and such, I think the tradeoff in terms of completion and tooltip/info access you make with vim over an IDE becomes void once you're hitting major major work though.
>>
>>57477336
intersect(intersect(A,B),intersect(C,D)) would show you the element they have in common, and if you wanted to do more than 4 arrays you'd just use recursion.

If you wanted to go the recursive path, you'd want to do intersect(A,B),intersect(B,C) instead of A,B C,D.
>>
>>57477351
ok, then how are state machines done in haskell?
>>
>>57477471
It's easy if you can describe all your states as an algebraic data type. Then you just use pattern matching.

The state monad will still help if you don't want to pass the state around your main loop or whatever but it doesn't really have anything to do with the state machine itself.
>>
Any Perl wizards lurking?
I'm trying to build a simple Curses interface and I've got a simple "text editor" thanks to a tutorial I found, but I want run_script() to change what the text displays as. Right now running it just causes it to crash back to the terminal.

use Curses::UI;
my $cui = new Curses::UI( -color_support => 1 );

my @menu = (
{ -label => 'File',
-submenu => [
{ -label => 'Exit ^Q', -value => \&exit_dialog },
{ -label => 'Run Script' , -value => \&run_script }
]
},
);

my $menu = $cui->add(
'menu','Menubar',
-menu => \@menu,
-fg => "blue",
);

my $win1 = $cui->add(
'win1','Window',
-border => 1,
-y => 1,
-bfg => 'red',
);

my $texteditor = $win1->add("text", "TextEditor",
-text => "here is some text\n"
. "and some more");

$cui->set_binding(sub {$menu->focus()}, "\cX");
$cui->set_binding( \&exit_dialog , "\cQ");

sub run_script()
{
$texteditor = $win1->add("text", "TextEditor", -text => "testtest\n");
}

sub exit_dialog()
{
my $return = $cui->dialog(
-message => "Do you really want to quit?",
-title => "Are you sure???!?!?!!",
-buttons => ['yes','no'],
);
exit(0) if $return;
}

$texteditor->focus();
$cui->mainloop();
>>
Fuck this shit. I don't have patience for this.
Emacs is almost as bad as MS Office.
>What the fuck now? Why did it do that? Why has this behaviour changed all of a sudden? I don't know what i did or how to change it back.
>>
>>57477513
>I'm going to use a text editor notorious for unusual keybindings
>Why are these keybindings so stupid?
You probably switched buffers or split the window without knowing how to switch back. Spend 5 minutes of time learning how to use it.
>>
>>57477460
Thank you based anon, I actually just ended up just putting the ismember of the first matrix with each of the others in a table and searching it for a row of all trues. Probably less efficient but it works.
>>
>>57477497
example?
how would yo do pic related
>>
>>57477524
>you can learn emacs in 5 minutes
fuck off
>>
>>57477553
data State = Locked | Unlocked

push :: State -> State
push Locked = Locked
push Unlocked = Locked

coin :: State -> State
coin Locked = Unlocked
coin Unlocked = Unlocked
>>
>>57477329
No it isn't.
>>
>>57470320
epic meme you insufferable shithead sperglord
>>
>>57477513
thank you
also, bindings are unintuivitive and you always have to think to do what you want
>>
>>57477513
>I get angry at things when they don't work the exact same way as the other thing that I'm used to

how do you even get better at anything with that attitude, as opposed to "oh I changed something, let's google this/look at my keybindings chart and see what button I pressed, oh that's what that does"

I don't understand why you'd even try to make the change if you're mad about the change. That's the point of the editors, not to be the same as everything else you've used.
>>
File: 1958201258.png (147KB, 815x627px) Image search: [Google]
1958201258.png
147KB, 815x627px
>>57477578
are you javafag by any chance
>>
>>57477572
thats it
state machines seem to be easy in haskell thanks to pattern matching
>>
File: roguelike.png (11KB, 714x338px) Image search: [Google]
roguelike.png
11KB, 714x338px
I'm writing a roguelike with ncurses.
>>
>>57477595
Indeed.
>>
>>57477595
ignore him

use comonads
>>
>>57477576
Why not?
>>
>>57477610
or comonoids
>>
>>57477590
kill yourself
>>
File: 721468.png (5KB, 348x90px) Image search: [Google]
721468.png
5KB, 348x90px
>>57477624
ayyyy he's back
>>
>>57477564
You can learn the basic controls in 5 minutes, yes.
Ctrl+V next page
Meta+V previous page
Ctrl+x+Arrow next/prev buffer
Ctrl+x+f open file/create new file
Ctrl+space start/stop highlighting
Ctrl+w Cut highlights
Ctrl+y Paste
Ctrl+x+s save
Ctrl+x+c close
Ctrl+x 2 Split window
Cltr+x o Switch window focus

Practice using it for 5 minutes and you'll have no issue. It sounds confusing but is surprisingly intuitive thanks to the positioning of the keys.
>>
>>57477610
>muh monads

>>57477595
>muh pattern matching
>>
>>57477620
Why would it be? Blocks introduce scopes, inner scopes can shadow outer names. This is basic shit, and common to all languages that aren't Javascript.
>>
>>57477637
>muh muhs
>>
>>57477637
most comonads aren't monads
>>
>>57477633
and i'm leaving straight away, i've been in /pol/ to help get trump elected, now i'm reminded of how much of a shitty waste of time /dpt/ is
>>
>>57477590
Can't you just make an object that stores a string and automatically casts the contents to the type?
>>
File: he's back.png (6KB, 350x93px) Image search: [Google]
he's back.png
6KB, 350x93px
>>57477653
>>
>>57477653
you're a disgrace to trump supporters, you sound like a whiny female, kill yourself for god emperor
>>
File: 80125012759.png (5KB, 353x104px) Image search: [Google]
80125012759.png
5KB, 353x104px
>>57477662
holy fucking shit
that filename
i didn't actually look at that when i picked it from my folder of screencaps of you
that's fucking amazing
>>
>>57477641
Just because that's how it's defined in the c standard doesn't mean it's not stupid.
>>
>>57477662
(You)

>>57477666
lol k tard, you're the ones who whine about java, when java really isn't a bad language you just suck at it, and meanwhile you fap to python and haskell which are objectively worse languages

>>57477675
that post is not me
>>
>>57477610
what are comonads again
>>
>>57477586
I have more interesting things to learn than the occult rituals of a text editor, right now.
I just wanted something that will make my work easier without getting in my way.
>>
Still trying to homebrew a rapid miner clone for shits and giggles.

It just has SOMs, kNN in different flavors and cosine similarity. Next up are MLP and SVM
>>
>>57477683
It's not stupid.
>>
>>57476898
it was popular. but the various companies owning delphi fucked it up for 10-15 years straight with ridiculous releases and insane costs. Delphi 5/6/7 was the last "good" delphi atleast until last time I checked in 2013 or so. the rad studio in 2013 was still awful. cross-platform development/deployment for mac was released in a pre-alpha state, barely functional and very painful to use. mind you the pascal language exists for as long as C and there have always been pascal compilers for unix and mac/OSX. but still they fucked up. maybe it has gotten better, but why not just use Qt instead. Better community, more features, stable, LGPL/GPL, widely used, interfaces with every C/C++ library,...
>>
File: 1471831710487.gif (979KB, 500x501px) Image search: [Google]
1471831710487.gif
979KB, 500x501px
I need to make a program that can modify contacts from a .csv file exported from Odoo in Java.
Anyone knows if I can find something similar already made. I'm a lazy piece of shit and don't know how and where to start.
>>
>>57477693
>I just wanted something that will make my work easier without getting in my way.
Yeah, vim and emacs are designed for that. That's the point of text editors, to give you tools to edit text. The tools are just used in different ways. Why do you think they're designed to get in your way just because you don't know how to use them? You'd be saying the exact same thing if you started with vim and then went over to VS.

>none of my bindings work
>I typed cw and it didn't change the word it just typed "cw" in the textbox
>why do I have to use the mouse just to switch source files wtf
>I pressed some function key and now the bottom bar is yellow and my program is frozen at some red dot on the side of my screen, why does it get in my way so much I want it to just work
>I have more interesting things to do I'm going back to vi

Do you see how stupid that sounds? Why did you bother to even try to switch in the first place if you aren't willing to learn?
>>
>>57477728
do your homework
>>
>>57477728
You can modify a csv easily enough in any spreadsheet program.
>>
>>57477728
it would probably be easy to parse and work with the file using python
I set up something quick for a tab delimited file in under an hour to create a histogram
>>
I'm currently creating an AI for PLO (pot limit omaha poker).
My previous solution was a decent 'training tool' for 100NL, but this time I'm looking to get close to GTO, on a scale of (for epsilon->0).
Giant search space ofc, but with some neat algorithms and cloud computing, that's no longer a problem.
>>
>>57477728
1. do your own homework
2. csv format is piss easy, literally, it will not got easier
3. java should not be the tool of choice for this task (any task)
4. pick another language
5. start buy using your brain, then google, then brain.
6. repeat 5 repeat until success
>>
>>57477739
Like this anon guessed >>57477738 it's a shitty homework in a shity class.

>>57477743
>>57477770
Well I never coded in Python. Is it fast to learn ? I mean I can't spend more than a week on this. I can use Javascript but it's been a while since the last time I coded with it so I would rather avoid it.
>>
>>57477785
>Well I never coded in Python. Is it fast to learn ?
If you can google
>How to open file python
>How to parse file python
And go to the first stackoverflow page that shows up, you should be fine
>>
>>57477785
python is a good choice and is reasonably easy to get used to.
>>
>>57477745
>pot limit omaha poker
>PLO
>not PLOP
>pot poker
ain't no one got time for a good lavatorial joke any more?
>>
>>57477734
>Why do you think they're designed to get in your way
I don't think this, and i never said this. But the reality remains that they do get in my way.
>You'd be saying the exact same thing if you started with vim and then went over to VS.
True. And irrelevant to my situation.

>Why did you bother to even try to switch in the first place
Because VS doesn't exist for linux, and i don't know what does that is comfy.
VSCode maybe? But i've heard it's not so hot with c++.
>>
>>57477825
>But the reality remains that they do get in my way.
How? Literally how? It's the exact equivalent of jumping in a car without knowing how to drive and then bitching that you don't have time or you have more interesting things to do than learn how to drive in a car, and it gets in your way. Learn how to use it and tell it what you want to do. Learn to speak it's language instead of complaining on an anonymous imageboard. Don't want to do that? Go back to your old editor. I too do not have time to learn another editor, which is why I'm not screaming that emacs "gets in my way" but instead just using vim or learning how to use emacs in the first place.
>>
>>57477825
Sublime text
>>
>>57477851
>Go back to your old editor.
I will, for now. I tried emacs, at least.

Man, i don't know why you're getting so upset about this. It's like i kicked your puppy, or something.
>>
>>57477859
I don't like how Sublime keeps nagging me for money.
>>
>>57477896
>Man, i don't know why you're getting so upset about this. It's like i kicked your puppy, or something.

Good old switcharoo. Complain about something, get upset about it not "working", get called out on being retarded, and then call the other guy upset. You're the kind of person that makes tech support want to kill themselves.
>>
>>57477825
I'm amazed somebody willing to use linux is so unwilling to take 5 minutes to learn a new interface for a new tool.

It's no different than any other editing tool or IDE, there's a learning curve before you can really take full advantage of the power it has to offer you.
>>
>>57477910
>Complain about something
>get upset about it not "working"
Yes, i did this.

>get called out on being retarded
I... guess. I cant' really argue with that. It's not like i'm not used to it.

>then call the other guy upset
He literally seems to me to be more upset at this situation than i am, at this point. I don't see why he should be so.
>>
>>57477963
>he
No, it's still me, guy. I could compare it to kicking a puppy, though I'd feel far worse for a puppy. Shit talking dogs because "it doesn't do what you want it to do" on an internet sub forum of people who often have dogs would be retarded, it's likely you just haven't house trained it enough. I'm questioning your slandering of a decent text editor. I really don't care in the grand scheme of things, I just have nothing else to do so I'm challenging your beliefs.
>>
File: Untitled.png (3KB, 406x58px) Image search: [Google]
Untitled.png
3KB, 406x58px
I'm trying to get into WPF/XAML and this is amazing, way more stable and faster than WinForms.
I'm migrating an old image viewer of mine from c# winForms to c# WPF and this shit can even handle 32K pictures without crashing or any performance impact on the CPU part. The only downside is the RAM consumption, I'm still trying to figure it out a way to compress big pictures without much loss.
>>
>>57477948
Because everything else is new as well.
Besides, the 5 minutes i spent with emacs, combined with discussion here, has made decide that emacs i not provide what i want from a code editor.
>>
>>57477963
>I don't see why he should be so.
Insulting somebody's text editor of choice is akin to starting a race war.
Some people get real upset about it.

I still think you should give emacs another go. Keep a cheat-sheet of keybindings open in a side window or something. Or use Vim, I don't really care, but dismissing both of them because you didn't want to take the time to learn the interface is silly.
>>
>>57478034
>everything else is new as well.
As in you're new to linux?
Too much too fast anon. Stick with nano or gedit or something until you're more comfortable. They're both very basic and have sort-of okay syntax recognition once you save a file with the proper extension.

Or notepad++
>>
>>57477991
>No, it's still me, guy
Irrelevant. Learn to anonymous image board.
>>
>>57478056
>again dismissing the rest of my point so you can select out one piece of text and make some stupid remark that has nothing to do with the subject matter, and then not address the actual subject matter

Irrelevant. Learn to debate. Reminder that you've consistently ignored my arguments that emacs is not getting in your way and not provided any proof to the contrary.
>>
>>57478020
>I'm trying to get into WPF/XAML and this is amazing
This is the first and probably last time I think I will ever see somebody say this.

WPF is a huge improvement over WinForms but christ if it isnt a pain to work in.

>2.5GB RAM
Make sure you're not unnecessarily keeping old images buffered or creating endless panes on top of each other
>>
File: 1457099210106.jpg (80KB, 487x851px) Image search: [Google]
1457099210106.jpg
80KB, 487x851px
I want to fuck Kotlin
>>
>>57478037
> Keep a cheat-sheet of keybinding
But that's the point. I could spend some time learning the keybinds, but they don't seem to provide the functionality i wan't in a code editor anyway, so i have no reason to do that.

>>57478050
Gedit and notepad++ is what i've been using. I wanted to see if there was something better out there.

>everything else is new as well
Not only am i not entirely familiar with linux, i'm also learning to work with an unfamiliar api, and that's what i want to spend my limited mental resources on.
>>
>>57478136
What exactly are you looking for in an editor
>>
>>57478081
You don't have a point to dismiss. You have opinions, that i'm not in a position to say anything more about without repeating myself.
>>
>>57478162
No, you're misunderstanding me entirely. Your first post was directly accusative and you have consistently said emacs "gets in the way of you". It is not my opinion that it does not, it is a contrary accusation, a call for you to prove/back up your statement with some form of actually constructive criticism so other anons who use emacs here can help you and so I can see why you actually think emacs is bad for you. You've made a blanket, generic and vague statement and I'm challenging you to refine that statement. I have no opinions on text editors, only opinions of people who complain uselessly about them (and anything else) without a description of the problem of some sort.
>>
>>57478086
>if it isnt a pain to work in
yeah, like I said, I really liked its performance and flexibility, but some things that were really simple and straightforward in forms can be a pain in WPF.

The buffer is clean, is that the default Image control in WPF eats up a lot of RAM, maybe I will look into some 3rd party control
>>
>>57478149
Good, IntelliSense tier, autocompletion and error checking, the ability to jump around and examine definitions through clicking in function calls, variables and macros.
Maybe a 'compile' and a 'run' shortcuts.
Preferably not a lot of other shit i'm not familiar with that will scare and confuse me.
>>
>>57472045
neat game
>>
I'm reading a C++ tutorial
>>
>>57478234
Emacs and Vim both absolutely have that
But, like most things in linux, it's going to require to configure some things.
https://truongtx.me/2013/03/10/emacs-setting-up-perfect-environment-for-cc-programming

And I'm sure you can find one for Vim just as easily.
Emacs and Vim are both so prominent and powerful because they essentially allow you to condense every IDE and editor you use for each language into a single one. I use JDEE and a fistful of Perl extensions and edit all of my Java and Perl inside of Emacs. I have autocomplete, error checking, debugging, the works. But I did have to configure and set it all up.
If I started working with C++ or C I wouldn't have to hunt down a new program, I'd just have to add more plugins to Emacs.
>>
>>57478204
I've made blanket, generic and vague statements, because that's what it felt like using emacs, to me. I am not in a position to give 'constructive' criticism. Only that using emacs felt like using ms office. I dare say if i had directed the same sentiment directly toward office, no one would have batted an eye.

At no point did i get the impression that you were interested in helping me. Only that you were very triggered by my opinion.
>>
>>57478289
Thanks, maybe i'll give that a read then.
>>
Is this on autosage if so I'm starting a new thread
>>
New thread: >>57478887
Thread posts: 337
Thread images: 37


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.