« first day (2601 days earlier)      last day (2344 days later) » 

12:04 AM
Mar 23 '16 at 22:27, by ArtOfCode
Let me just drop a reminder in here: Be Nice. No matter who it is, whether you like them or not, it is a requirement of chat that everyone is nice to everyone else. Professional respect is a great thing.
Huh, so this is the most starred post on the chat, according to a script I wrote.
I was hoping for something funnier, so this kind of seems like a waste of time...
 
@SirCumference Yeah, I was flicking through the starred posts on Worldbuilding earlier (nowhere near as many as on here) and the few highest ones are all mod posts either reminding people something similar or admin stuff (e.g. so-and-so got elected as a mod)
 
I did not star that btw
I want to downvote it, in fact
Hail Satan
 
@DanielSank I'd be content with just the Nice Answer badge, so I can get an astronomy hat...
 
@SirCumference Just one star less:
Jul 7 at 20:07, by dmckee
Hard for things to be going much better: I'm a father as of today.
 
@SirCumference /me abuses mod edit powers to fix an 18-month-old typo
 
12:18 AM
@ArtOfCode There's got to be a hat for that, surely :P
 
@ArtOfCode What typo?
 
@SirCumference "is is"
s/is/it/
 
@ArtOfCode Ah
 
1:16 AM
Allo... Anyone here can recommend a good editor for .bib files on a Mac?
 
1:49 AM
@ACuriousMind our love is a farce
 
2:22 AM
@ZeroTheHero I use emacs. But then I use emacs for a lot of things.
There is a bibtex mode, so you get highlighting, and it can insert blank entries, though I rarely bother.
 
 
1 hour later…
3:30 AM
0
Q: Renaming visible-light?

David ZI've noticed the visible-light tag has a tendency to be incorrectly applied in cases where the OP happened to have visible light in mind when they asked the question, but they are really asking about electromagnetic radiation in general. (recent example, and there are many other visible-light que...

 
4:22 AM
Hi everybody
@ZeroTheHero vim
That's sort of a joke
 
@dmckee That's an interesting suggestion. I used emacs many years ago and I quite liked it. I find BibDesk terribly frustrating.
@DanielSank wow... vim is still out there? That must go back like 25 years.
 
Vim and emace both still exist and are still locked in a holy war of text editors ;)
 
The Crusades lasted 200yrs or so.
I am under pressure to convert to systematically using bibtex files...
 
5:22 AM
@ZeroTheHero yeah I write all my Python and TeX with vim.
Vim is absolutely amazing. The basic stuff and plugins make editing code so easy and fast.
 
Anonymous
6:04 AM
@JohnRennie Hi, you there? I installed this autocomplete package (atom.io/packages/autocomplete-python) on the Atom editor but but I'm not sure how to activate it
 
@Blue morning
 
Anonymous
I have the Scripts package already installed
 
Anonymous
@JohnRennie Good morning :)
 
Is that Windows or Ubuntu?
 
Anonymous
I'm on Windows currently
 
Anonymous
6:06 AM
Earlier I just used to execute the .py files from cmd
 
Anonymous
But that autocompletion stuff is useful to have
 
Anonymous
I think Atom works for Ubuntu too, got to try
 
I've no idea I'm afraid. I had never even heard of the Atom editor.
 
@Blue Is that an external editor?
 
Anonymous
@PrathyushPoduval It's just a text editor
 
Anonymous
6:09 AM
@JohnRennie Oops. Which IDE do you use?
 
Oh okay
 
@Blue I use an editor called Codewright that is probably older than you are :-)
 
Anonymous
Hehe. Actually Atom is useful because I can sync it with Github
 
For Python I don't use an IDE because I don't write much Python. For C++ I use Visual Studio.
 
I prefer the simplicity of IDLE, you're not overloaded with lots of buttons and other shitz
 
Anonymous
6:11 AM
@PrathyushPoduval IDLE is awfully restricting. It's useful for beginners
 
restricting in what sense? I never had any trouble with it
 
Anonymous
But doesn't offer syntax checking or autocompletion like an IDE should
 
I didn't want those features. They just clutter the screen for me
 
Anonymous
@PrathyushPoduval Heh...
 
Notepadd++ also has them, i use it for c++
The black backgroud also strains me eyes
 
Anonymous
6:15 AM
It seems I need to install Kite first
 
Anonymous
@PrathyushPoduval Also IDLE can't manage to sync your Github projects, nor can you navigate between the Python files on your system from within IDLE
 
Anonymous
It is used normally to teach beginners. No professional would use it
 
Anonymous
@PrathyushPoduval You can always change background color
 
I haven't started using githuh yet (I think I should soon :P) why not use file explorer for navigating?
@Blue ah yeah, I never tried that out :P
 
Anonymous
@PrathyushPoduval Using file explorer to navigate is a pain in the ass
 
6:20 AM
I have vs code installed, I'll try it out there and see if I can adjust to it
 
Anonymous
Ah, I heard of vs code
 
@Blue I usually have the important folders opened while I'm writing my code so I can navigate it easily while writing
 
Anonymous
This looks useful: kite.com
 
What do you need that for now?🧐
 
@Blue I've been programming since well before you were born, and I don't use an IDE. Well, I do use VS but I don't use many of the IDE features. I use GIT from a command line.
I'm not saying this is the right way to code. I'm just saying it is one way to code.
 
Anonymous
6:31 AM
@JohnRennie I was talking about IDLE...you probably don't use IDLE to code, do you?
 
I don't know what IDLE is ...
 
As long as I can run my code from the editor, I'm fine
 
IDLE (Integrated DeveLopment Environment or Integrated Development and Learning Environment) is an integrated development environment for Python, which has been bundled with the default implementation of the language since 1.5.2b1. It is packaged as an optional part of the Python packaging with many Linux distributions. It is completely written in Python and the Tkinter GUI toolkit (wrapper functions for Tcl/Tk). IDLE is intended to be a simple IDE and suitable for beginners, especially in an educational environment. To that end, it is cross-platform, and avoids feature clutter. According to the...
 
Anonymous
@JohnRennie Huh...it comes built in with Python...
 
@JohnRennie python editor which comes with python
 
6:32 AM
Presumably that's what you mean ...
 
Anonymous
@JohnRennie Right. That's an in-built crude editor that comes with the Python 3 install. You surely don't use that. :P
 
I use a separate text editor and run the program from the command line.
 
Anonymous
I was telling Pratyush why IDLE is awfully restricting
 
Anonymous
Hehe
 
Anonymous
6:34 AM
@JohnRennie I used to do the same. But it is very useful to have autocompletion and function documentations (pop up) when you are writing programs
 
But as I mentioned earlier I don't do much Python work. The longest app I've written in Python is only a few thousand lines.
@Blue I must admit that when I'm doing hard core C++ hackery I find it enormously helpful that VS shows me class methods etc as I'm typing :-)
 
Anonymous
@JohnRennie Yeah, that's the thing! :)
 
If I were writing similarly sized apps in Python then yes I'd also want those facilities.
 
Maybe that explains the awful amount of googling I do while writing code......
 
Anonymous
@PrathyushPoduval Start using a real IDE :P
 
6:37 AM
@Blue Like PyCharm..
 
Anonymous
@Ihsan Yup. PyCharm had some issues on my machine though....
 
Anonymous
I'll try to install it again
 
@Blue what issue ??
 
Anonymous
@Ihsan Couldn't find the interpreter even though it was in the same folder
 
Anonymous
6:40 AM
I did. It wasn't working. I'll try again. later
 
well good luck..
 
Anonymous
7:18 AM
Phew phew...finally made Kite work (integrated with Atom).
 
Anonymous
All documentations pop up immediately along with autocomplete..yay :)
 
Anonymous
Had to install the python-language-server
 
@Blue cool :-)
 
Anonymous
7:34 AM
@JohnRennie Just dowloaded Visual Studio (the professional 2017 version). For C/C++ programming which one to install "Desktop Development with C++" ?
 
Anonymous
 
Yes, you only need the "Desktop development ..." option. You can always add other options later if you need them.
Why did you download the Pro version when the Community edition is free? Or does your university provide a Pro licence?
 
Anonymous
@JohnRennie It actually didn't mention anything about which one is free, here
 
Anonymous
Should I get the Community instead?
 
Anonymous
No, our university doesn't provide any license
 
7:37 AM
Though actually I suspect it's the same installer and it installs the Community Edition unless you provide a licence ...
 
Anonymous
 
Anonymous
Alright...done
 
Anonymous
I'm selecting the Desktop option...
 
Anonymous
wtf...it is 6.25 GB!
 
Anonymous
 
Anonymous
7:40 AM
Which options do I select here? @JohnRennie
 
Anonymous
I just need support for C/C++ code. Nothing more
 
As I recall the only extra option I chose was "C++/CLI support". I think that gives you the ability to compile from the command line,. which can be useful for compiling other people's code.
 
Anonymous
That reduces it to 2.02 GB :P
 
Anonymous
Done!
 
Anonymous
Downloading now
 
7:53 AM
Hi!
@Qmechanic Hi, In which field of Theoretical Physics do you work in?
 
Anonymous
@SwapnilDas QMech is a shady AI who knows and works in every field of TP that mankind ever treaded.
 
Sid
Who is not an AI around these parts?
 
Anonymous
Duh, only ACM and QMech are AIs. Others are petty mortals
 
Sid
@Blue JR is a petty mortal? Don't stir the broth too much. :P
 
8:09 AM
mornin
 
Anonymous
 
Anonymous
@JohnRennie What to do next? How do I execute the code?
 
Anonymous
I'm not even sure this is the right way to do it
 
Anonymous
I created an empty .txt file and wrote the code in it
 
Anonymous
And then changed extension to .c
 
8:17 AM
Typically you start by creating a new project. VS will ask for the directory and it will create the directory and the makefiles etc.
Then you add a C/C++ file and type in your code.
To run it click the debug menu and choose Run from there. You can run it in the debugger or not as you choose.
Hard core VS users just press F5 to run in the debugger or ctrl-F5 to run without the debugger.
 
Anonymous
 
Anonymous
I get this error when I try to open a New Project (empty) in Desktop
 
Hmm, something has gone wrong with the install then. I've just tried creating a new empty project on the Desktop and it worked just fine.
 
user228700
::Runs in, gesticulating wildly, in celebration::
 
@Blue like so?
@Kaumudi.H EXAMS ARE OVER!!! :-)
 
user228700
8:24 AM
YES!! :-)
 
user228700
I'm going hooome!
 
user228700
16 hours ago, by John Rennie
user image
 
user228700
Sausage pizza?
 
@Kaumudi.H Yes. It was deeeeeeeeeeeeeeeeeelicious :-)
 
Anonymous
 
Anonymous
8:27 AM
I made the folder manually on Desktop
 
Anonymous
And created the cpp file like you said
 
user228700
@JohnRennie Cool! :-) Dyou remember the order of pizza and garlic breadsticks that I had made the other day, but could not place because the website was offline?
 
Anonymous
But then....it's showing a new error :/
 
Anonymous
@Kaumudi.H Great! :)
 
user228700
@Blue :-) I see you're having fun.
 
8:28 AM
@Kaumudi.H Yes ... ?
 
user228700
Well, I ordered it today!! :-)
 
@Blue what does the Tests Output Pane show?
@Kaumudi.H Enjoy your sausageless pizza! When are you leaving for Chennai?
 
user228700
@JohnRennie :-) My train is in 4 hours, but we're leaving in another hour and a half, I think. I haven't even started packing, lol.
 
Anonymous
@JohnRennie Which one is the test output pane? I can't see the output anywhere
 
Anonymous
[18-12-2017 01:56:01 PM Error] Object reference not set to an instance of an object.
[18-12-2017 01:56:01 PM Informational] ------ Load Playlist started ------
[18-12-2017 01:56:01 PM Informational] ========== Load Playlist finished (0:00:00.0120106) ==========
[18-12-2017 01:59:34 PM Warning] The build was canceled or Failed.
[18-12-2017 02:00:16 PM Warning] The build was canceled or Failed.
[18-12-2017 02:01:05 PM Warning] The build was canceled or Failed.
[18-12-2017 02:03:36 PM Warning] The build was canceled or Failed.
 
Anonymous
8:34 AM
Found it
 
Anonymous
@JohnRennie Wait, I need to download gcc?
 
No, you don't need to download gcc
I'd guess something has got a bit screwed with the install.
I need to work for half an hour or so now.
 
Anonymous
 
Anonymous
@JohnRennie Sure, I'll try something meanwhile
 
@Blue Try creating a new project, but instead of Empty Project choose Console Application. That is after all what you are creating.
 
Anonymous
8:40 AM
Alright, trying
 
Anonymous
@JohnRennie I reinstalled the whole VS application after deleting it. And then tried creating Console Application. But it still shows the same error.
 
Anonymous
Project 'ConsoleApplication1' could not be loaded because it's missing install components. To fix this launch Visual Studio setup with the following selections:
Microsoft.VisualStudio.Component.VC.Tools.x86.x64
 
Anonymous
Anyway, we can discuss once you get back from work
 
10:16 AM
@Blue you around?
 
Anonymous
10:34 AM
@JohnRennie I am now :)
 
It turns out the C++/CLI isn't necessary after all, though it shouldn't be causing any problems.
Anyhow shall we go check the install now?
 
Anonymous
@JohnRennie In the reinstall I didn't include that option
 
Anonymous
@JohnRennie Okay
 
@vzn I see you have returned :P
 
OK. Press Windows-R and run control
 
Anonymous
10:35 AM
done
 
Then in Control Panel click Program,s and Features
 
Anonymous
done
 
Then select Microsoft Visual Studio Installer and click Change
 
Anonymous
Yup it's open
 
Delete system 32
 
10:38 AM
If you click the More link then select Modify you should get:
 
Anonymous
@0celo7 I had done that once...to convince my father to buy a new laptop....
 
Anonymous
Around 7-8 years ago
 
Anonymous
@JohnRennie There's only ""Repair" and "Uninstall"
 
hang on ...
mum's on the phone ...
 
Anonymous
Sure
 
10:41 AM
@Blue that’s immoral
 
Anonymous
@0celo7 I was immoral back then
 
morality => mortality
always be immoral
 
@Blue then there's definitely something wrong ...
 
Anonymous
@JohnRennie Wait, there's Modify option outside "More.."
 
Anonymous
I think that's it
 
10:44 AM
Ah :-)
 
Anonymous
@JohnRennie Yeah, I get that
 
@Blue It looks the same as in my image?
 
Anonymous
 
Anonymous
I just downloaded the core during reinstall
 
Ok. I'm not sure what the core includes.
 
Anonymous
10:52 AM
Any idea what exception from HRESULT mean?
 
Anonymous
That's what it shows during project creation
 
Anonymous
Project 'TestConsole' could not be loaded because it's missing install components. To fix this launch Visual Studio setup with the following selections:
Microsoft.VisualStudio.Component.VC.Tools.x86.x64
 
Anonymous
How do you "launch" VS using that selection? @JohnRennie
 
Anonymous
I think I need to instal the VC toolset
 
I would uninstall.
Then restart then delete C:\Program Files (x86)\Microsoft Visual Studio just to make sure it's all gone.
Then do a fresh install selecting the "Desktop development with C++" as before and leave all the options at the defaults.
 
Anonymous
10:57 AM
Alright, I'll try that! But one question: Is VS really worth it? It takes up 6GB of space if I install all the toolkits it recommends, or should I continue with some other IDE?
 
Then restart, just to make sure, then try running VS.
If you need to do C++ development then VS is the best IDE there is.
 
Anonymous
@JohnRennie Ah, I see. Okay, I'll reinstall it then
 
Anonymous
Thanks
 
I've used it for working on Kodi, which has millions of lines of code (I forget exactly how many millions :-)
 
Anonymous
Haha
 
Anonymous
11:15 AM
Reinstall done. Now it can create new projects fortunately! But:
 
Anonymous
 
Anonymous
@JohnRennie
 
If you want I can have a look. You'll need to (temporarily) install TeamViewer ...
 
Anonymous
Alright!
 
Anonymous
Basic installation?
 
11:19 AM
@Blue remind me what the options are ...
 
Anonymous
 
Ah, yes, basic is fine, or if you choose Run only it won't install anything. It will just run a temporary copy to allow me to connect.
You also need to choose Personal use
 
yo
 
When TeamViewer starts you need to mail me your ID and password on Facebook. If you post them here you'll be allowing anyone to connect :-)
 
Fiv
11:35 AM
rennie
teach these
nuclear reactions
me
on tw
 
Anonymous
@JohnRennie On from my phone now
 
Anonymous
You can continue
 
Cool, let me bring up VS
 
Fiv
john
u seem like
refused it
 
So File/New project
 
Anonymous
11:36 AM
Ok
 
And I'm going to choose the console app
 
Anonymous
Ok
 
All I need to do is choose the name, then when I click OK it will create the project and create a template C++ file.
 
Anonymous
Right I see the c++ file
 
To compile choose Build/Build solution or use VS hackers just use the shortcut ctrl-shift-B
 
Fiv
11:38 AM
lol
I'm c++
 
@Fiv hi Fiv, I'll get back to in a moment. I'm just talking someone through their first VS2017 project.
 
Anonymous
@JohnRennie Right. But doesn't that throw exceptions ?
 
@Blue there's a load of junk in the output window that you can ignore.
 
Anonymous
Alright
 
What you want is the output from the build step. Watch what I select now ...
 
Fiv
11:39 AM
@JohnRennie Thanks, I'm waiting then.
 
@Blue OK?
 
Anonymous
Mmm...You select Build
 
Anonymous
In the output section
 
Anonymous
Ok
 
The Build windows shows the results of the build. In this case successful.
 
Anonymous
11:41 AM
Aha!
 
Anonymous
What if we print something now ?
 
You don't need the Test window open. I wonder how we close it ...
@Blue Do you want to add some code or shall I?
 
Anonymous
@JohnRennie I'm adding..one sec
 
Succeeded! :-)
 
Anonymous
Ah. Where is the Hello getting printed ?
 
11:43 AM
If you run it then the console will just flash up and disappear again.
You can add a scanf or gets or something to keep the console open ...
 
Anonymous
How to run ? From Test?
 
To run it choose Debug/Start without debugging or just press ctrl-F5
@Blue after you make a change you need to build the project again
It's a compiler not an interpreter like Python.
 
Anonymous
@JohnRennie Oh. Doing that!
 
OK, it's telling you not to use scanf
The build failed because scanf is a deprecated function.
 
Anonymous
Lol. gets will work ?
 
11:47 AM
There's an option somewhere to tell it not to be so fussy ...
Use getchar. That's safe.
 
Fiv
@JohnRennie Do you think significant digits is important for atomic calculations?
 
Anonymous
@JohnRennie Does it look okay now ?
 
Looks fine to me.
 
Anonymous
Yahoooo :D
 
When you press a key getchar will return and the app will exit so the console will close.
 
Anonymous
11:51 AM
Yep. Done!
 
One last comment re header files
 
Anonymous
@JohnRennie Okay ?
 
VS uses it's own header stdafx.h that includes all the usual headers
So you don't need <stdio.h>
(or at least I don't think so)
 
Anonymous
@JohnRennie Even for C files ?
 
Yes
 
Anonymous
11:52 AM
For C++ files I think it adds automatically
 
Anonymous
Got it though
 
Anonymous
Well, thank you so much :P
 
Shall I show you how to use the debugger?
 
Anonymous
@JohnRennie Yes !
 
Just go to the Debug menu and choose Step into
 
Anonymous
11:54 AM
Ok
 
Do you want to do the honours?
 
Anonymous
@JohnRennie Ah, what's that?
 
I mean you click on the menu
 
Anonymous
Clicked on Step Into
 
Ok now you're debugging
 
Anonymous
11:56 AM
Umm, how ?
 
To step forward one line select Debug/step over or it's quicker to press F10
That executes your app one line at a time
 
Anonymous
Got it !
 
Anonymous
Yay!!
 
When you F10'd at the return line it returned you to the bit of the run time library that called main
This is rarely useful :-)
More useful is setting breakpoints.
Let me quickly add some lines ...
 
Anonymous
@JohnRennie Gotcha :)
 
11:59 AM
@JohnRennie so scanfs not being used anymore, that's wonderful to know.......
 
Fiv
@JohnRennie Are you busy?
 

« first day (2601 days earlier)      last day (2344 days later) »