• Breaking News

    Thursday, August 30, 2018

    Last year I decided to teach myself to program, today my startup went into beta. learn programming

    Last year I decided to teach myself to program, today my startup went into beta. learn programming


    Last year I decided to teach myself to program, today my startup went into beta.

    Posted: 30 Aug 2018 07:09 PM PDT

    I just wanted to thank you all for all of the advice I've gotten by reading though this sub over the past year. Your contributions help more than you know. My site, Chat Circles, just went into beta and I owe a bit of the fact that I got here to you all. Thank you!

    submitted by /u/WhiteRiceWill
    [link] [comments]

    New Playground and Cheatsheet for Learning Python

    Posted: 30 Aug 2018 07:31 AM PDT

    I'm learning Python and I decided to create a repository where I could put Python script samples with standard Python syntax, structures and statements examples just to be able to quickly recap how to use this or that feature of the language.

    Here is what I've got.

    This is a collection of Python scripts that are split by topics and contain code examples with explanations, different use cases and links to further readings.

    It is a playground because you may change or add the code to see how it works and test it out using assertions. It also allows you to lint the code you've wrote and check if it fits to Python code style guide. Altogether it might make your learning process to be more interactive and it might help you to keep code quality pretty high from very beginning.

    It is a cheatsheet because you may get back to these code examples once you want to recap the syntax of standard Python statements and constructions. Also because the code is full of assertions you'll be able to see expected functions/statements output right away without launching them.

    How to Use The Repo

    Each Python script in the repository has the following structure:

    ```python """Lists <--- Name of the topic here

    @see: https://www.learnpython.org/en/Lists <-- Link to further readings goes here

    Here might go more detailed explanation of the current topic (i.e. general info about Lists). """

    def test_list_type(): """Explanation of sub-topic goes here.

    Each file contains test functions that illustrate sub-topics (i.e. lists type, lists methods). """ # Here is an example of how to build a list. <-- Comments here explain the action squares = [1, 4, 9, 16, 25] # Lists can be indexed and sliced. # Indexing returns the item. assert squares[0] == 1 # <-- Assertions here illustrate the result. # Slicing returns a new list. assert squares[-3:] == [9, 16, 25] # <-- Assertions here illustrate the result. 

    ```

    So normally you might want to do the following:

    • Find the topic you're want to learn or recap.
    • Read comments and/or documentation that is linked in each script's docstring (as in example above).
    • Look at code examples and assertions to see usage examples and expected output.
    • Change code or add new assertions to see how things work.
    • Run tests and lint the code to see if it work and is written correctly.

    Table of Contents

    1. Getting Started
    2. Operators
    3. Data Types
    4. Control Flow
    5. Functions
    6. Classes
    7. Modules
    8. Errors and Exceptions
    9. Files
    10. Additions
    11. Brief Tour of the Standard Libraries

    I hope you find this repository helpful!

    submitted by /u/trekhleb
    [link] [comments]

    CS student learning Python on Udemy. When should I pick up another language?

    Posted: 30 Aug 2018 08:29 PM PDT

    Sometimes I think I may be wasting my time. I thought coding would be a good skill to pick up and I still feel like that's true. However, I hear people generally talk negative about Udemy. I need an organized lesson to learn something, I can't just go around with jumbled information. Need a base..

    https://www.udemy.com/python-the-complete-python-developer-course/ This is the course I'm currently enrolled in.

    I want to also try learning C++ after but not sure how long after. (I bought a C++ program also).

    I'm still very much a beginner I would say. I'm dedicating like 1 hour and a half a day. Sometimes 2.

    I want to actually start building useful apps that could be anything but don't know where to start. I however want to learn both those languages before I even try.

    Btw I'm only in Intro to CS atm.

    submitted by /u/juravenator99
    [link] [comments]

    Store as string , enum or a another table in SQL database?

    Posted: 30 Aug 2018 11:38 PM PDT

    Recently i faced a dilemma regarding what datatype to store in database.

    ​My table has new field "UpdatedBy" which covering different users from different 3rd party integrations.

    It can be

    • admin from System X
    • assistance manager from System Y
    • user from the System itself

    "UpdatedBy" can be useful when audit, but not needed during normal operations. more 3rd party integrations to add later.

    I'm thinking to save them as

    • one field, string UpdatedBy "system_x:username1", "system_y:username2"
    • two fields, string UpdatedByName & enum UpdatedBy (specify which system it from)
    • create Many to Many tables

    May I know which practice is ideal for above scenario? Thanks.

    submitted by /u/appershopper
    [link] [comments]

    Which language is the best for learning functional programming with interactive tutorials?

    Posted: 30 Aug 2018 10:55 PM PDT

    I have a reasonably good understanding of Javascript and want to learn something of a different paradigm in order to broaden my programming horizons. I have spent a bit of time looking at Scala and Elixir, but didn't particularly like either. Scala seems very hard to learn without Java knowledge, and I hear a lot of worrying things about the community. Elixir has better long term prospects, but I don't like that the syntax is lightweight to the point of being unclear and it uses English words to mean completely unintuitive things.

    Ideally what I'd like is a language with some industrial relevance (no FP language is terribly popular in industry I know, but something with niche use at least would be preferred) that has really good tutorials incorporating minimal assumed knowledge and exercises/interactivity. Can anyone suggest a good candidate?

    submitted by /u/Muscular_carp
    [link] [comments]

    Lua

    Posted: 30 Aug 2018 10:14 PM PDT

    Can someone suggest sites/books to learn lua I started a course on edx for game programming and want to learn it

    submitted by /u/lokaranjan
    [link] [comments]

    I tried to download eclipse for Java, but it won't run. It says I need 1.8 or higher?

    Posted: 30 Aug 2018 10:01 PM PDT

    I tried the eclipse link given to us in the college website, and it's not opening.

    This is the laptop I own: MacbookAir

    And this is the link I used to download Eclipse : Mac OS X (Cocoa) 64-bit

    And it said to also download this : Download Java for OS X 2017 -001

    But I am being redirected to the link linked above

    submitted by /u/Girl_inSaree
    [link] [comments]

    Anyone here make an interesting transition to programming from an unexpected lifestyle or occupation?

    Posted: 30 Aug 2018 10:00 PM PDT

    Like former pig wrestler at the country fair turned coder..

    submitted by /u/kalrah
    [link] [comments]

    I feel as if I've been going in circles for months

    Posted: 30 Aug 2018 02:28 PM PDT

    Little background: I recently graduated from a bootcamp where I learned Python and a speciality language, which I thought was going to be javascript but they ended up just teaching us jQuery. After graduation I learned CSS and javascript by myself because I wanted to work in the front-end. My portfolio is basically non-existent, just random games from tutorials and some projects from the bootcamp. I've been searching for a job this past month and after several phone interviews realize I am severely under-qualified. I recently got laid off from my old job as well so that adds some pressure from my gf/ family to focus on landing something soon.

    My problem is I start off with an idea (like create a responsive portfolio website) and get overwhelmed by researching all these different technologies like adobe/wordpress/flexbox/css grid/ bootstrap. So I spend about a week learning flexbox, then learn I need a bundler and pre-processor so I research gulp and Sass. I am really having trouble sticking to one project without looking at job postings and seeing they need someone with wordpress experience so I try to learn that, then I realize my javascript isn't as up to par as I'd like so I spend a couple days reviewing promises and the fetch api and then I come up with a new project I'd like to start and the process basically repeats. I've been doing this for over a month now and nothing to show for it. I've read about tutorial purgatory and the easiest way out is to start building something, but I'm getting stressed seeing all these things I don't know and feel like I can't really do anything.

    I'm sorry for the rant, but I just don't know where my priorities should be at this point. Should I focus on creating a personal website to show employers or should I work on more projects for my portfolio? Any advice on which direction I should be going would be greatly appreciated. Thank you for reading, sorry it was a bit long.

    submitted by /u/cubicuban
    [link] [comments]

    First Project: Texas Hold 'Em.

    Posted: 30 Aug 2018 11:18 AM PDT

    Hello all,

    https://pastebin.com/L4S1vH4j

    https://github.com/tomophilia/Texas-Hold-Em

    Python 3

    For my first project, I wrote a Texas hold em game. As of now, you can only play with friends (or as all players).

    I read the first chapter of Fluent Python and liked his deck of cards code so much, I had to make a game.

    You play as "Tom" and your cards are displayed throughout the hand.

    This a full Texas Hold Em game. I know there are some kinks to work out still here and there but I have tested this thing exhaustively.

    I'd like any feedback you think is relevant or if anyone has questions, I'd be glad to help!

    I am split between trying to add a GUI or trying to add an AI that can play against the player. Both are kinda intimidating but, so was this when I started.

    This was mostly made in Pythonista on iPhone.

    Thanks again!

    Thanks for checking it out. I have been studying for about a year.

    submitted by /u/tomophilia
    [link] [comments]

    Help With Integrating an API

    Posted: 30 Aug 2018 09:47 PM PDT

    Hey guys/girls. I am looking for someone who would be interesting in helping connect my current app with an API. I am not all that familiar with these things and will gladly compensate someone to do so. I have provided the API documentation link here. https://tookanapi.docs.apiary.io/

    submitted by /u/Spacehero00
    [link] [comments]

    I can't get myself into C++.

    Posted: 30 Aug 2018 09:46 PM PDT

    I have found both Visual Studio and codeblocks to be terrible IDEs and I am having a hard time understanding how I can use C++ to do game design. It has no graphics or window libraries and it's annoying to get projects to compile my code properly. It's really easy in Java and Javascript to code games and draw them, but Java has a bad reputation as far as I know and no one wants to play a game from a .jar file. Javascript is annoying and I hate all my code in one file. I want to use a language that a lot of devs are using in order to create video games. What should I do?

    submitted by /u/pebble255
    [link] [comments]

    LinkedList.

    Posted: 30 Aug 2018 08:38 PM PDT

    Can anyone tell me the application of linkedlist in real world application?

    submitted by /u/praan2413
    [link] [comments]

    How to stack, stack views in xcode 9 (iOS 11) so they completely overlap and are both constrained to the bottom?

    Posted: 30 Aug 2018 04:44 PM PDT

    I'm trying to make a row of buttons on the bottom of the screen and the buttons are images. I was having aspect ratio issues so a few sites recommended making image views and simply put transparent buttons on top of them. I've placed six image views in a stack view and constrained it to the bottom. I thought it would make sense to put six buttons in another stack view and then also constrain it to the bottom, but it always constrains to the nearest neighbor so now the images are actually on the bottom of the screen, but the transparent buttons are vertically sitting above them. Is it possible to have both constrained to the bottom of the screen so that they completely overlap? Thanks!

    submitted by /u/ThatsIsJustCrazy
    [link] [comments]

    CS/Networking Theory question

    Posted: 30 Aug 2018 08:25 PM PDT

    I am an SWE intern, working on Web Acceleration team, in one of the largest satellite internet providers. I do most of the work for the below project, however, my supervisor helps me a lot with guidance and some coding parts. So my question is will this project work, in theory.

    GOAL: Achieving a user perception that the requested webpage loads faster as well as reducing latency effect.

    PROJECT DESCRIPTION: 1) Our server receives HTTP request from an internet user for some URI 4) Server sends a request to my application over a UDP connection, to render the specified URI 5) My app receives the request and uploads the HTML for the requested URI using 'request.js' 6) HTML is parsed it to get the list of all URLs for the dependent resources of the webpage 7) All dependent resources are fetched using 'request.js' 8) Fetched objects are then sent back to the processing server via TCP connection 9) Server sends resulted data back to the user via satellite and TCP/IP

    The program is written in JavaScript/Node.js using open source libraries and packages.

    I was reading and researching a lot on prefetching, prerendering and accelerating web traffic. Most of it involves some kind of prediction algorithm, data structure such as lookahead cache etc.

    I did mention it to my boss. He agreed but brushed it off in some academic way saying that the goal is to reduce perceived latency not the actual one. However, he plans on deploying it if it works and can pass the load tests

    I just want to make sure that the final product would be useful and not just be put in a pile of other intern projects. Especially, since I am going to school full time and working on this assignment full time, which literally translates into 70 hours work week. I extended my internship for this, hoping that I would get more permanent position(even if it's not well paid)

    I would really appreciate any input or advice on how can I make this actually work.

    Sorry for the long post

    (almost everything in this post is open source general information)

    submitted by /u/likecheesy
    [link] [comments]

    Full Time Immersive or Part-time

    Posted: 30 Aug 2018 08:28 AM PDT

    I am in the middle of a mid-life crisis at 30. I saw myself at some other place at this point of my life. I am currently an IT Service Desk Technician that gets overpaid for what I do. However, I work in a company that has 0 respect for any of the employees although the benefits are good as well. It seems like I am constantly stuck and unable to cross that road from IT Support to the "next level". I have my masters in IT but am not proficient in anything yet to get another position.

    I am not currently sure where I should go with my career. I was looking into all options, some of them being a Business Analyst, Project Management and possibly programming. I did pretty well in programming back in High School and College but didn't do that well when it came time for data structures etc (mostly because I was working a full time job and taking night classes).

    I started to look into learning python since most of the jobs I seemed to be interested on indeed required some variation of python learning. I am mixing up my learning with reddit / codecademy / ATBS / Learn Python the Hard way (which I stopped after reading reddit reviews). However, I am afraid that I will not go passed the intro lessons of strings and numerals and learn better with a fire lit under my a$$ (in person schooling).

    My dilemma is this, I am unsure whether the part time bootcamp classes are worth it. A friend of mine did GA immersive UX and told me that he recommends immersive over part time, but that would require me to quit a job with good benefits and pay while having a wife and a mortage with other expenses.

    Reddit, please help!

    submitted by /u/jmedayil
    [link] [comments]

    Python or Java for my purposes?

    Posted: 30 Aug 2018 04:19 PM PDT

    I'm in highschool, and in my Spanish II class we have to do Quias. Basically it gives you the english word and you type the spanish. Unfortunately we have to do 10 of these...each averaging around 40 questions...and that's just for 80%. We need to do 12 for the other 20% (stupid system, ik). I've gotten pretty tired of it especially since one of them has NINETY(90) words. What programming language would be most useful for making a bot to autofill for me? I've heard good things about Python and Java but I am open for suggestions. I would also like it to be universally useful (useful for most stuff>

    submitted by /u/Bluesywalnut
    [link] [comments]

    C++ Project involving concurrency?

    Posted: 30 Aug 2018 12:28 PM PDT

    I'd like to learn about concurrency in C++ and thought it would be nice to apply to some project. Can't really think of any though, please nothing to do with hardware (don't want to buy anything).

    submitted by /u/eatingpoopinrobarts
    [link] [comments]

    NitPicking101: Which style of logic do you prefer and why?

    Posted: 30 Aug 2018 04:04 PM PDT

    There is a little flow pattern that is rather ubiquitous in programming and I thought maybe some other thoughts might be interesting, I realize ultimately it is of little importance.

    This is just one example, and just happens to be in java. It is a made up function in a Tic Tac Toe game that switches between players X and O (an enumerated data type in this example). So it might get run after each turn.

    I will post each method as a separate comment.

    Method 1: An if statement for one case, and then a default for any other case.

    private void switchWhichPiecePlaysNext() { if (whichPiecePlaysNext == Piece.X) { whichPiecePlaysNext = Piece.O; } whichPiecePlaysNext = Piece.X; } 

    Method 2: An if-else statement for the 2 possible cases.

    private void switchWhichPiecePlaysNext() { if (whichPiecePlaysNext == Piece.X) { whichPiecePlaysNext = Piece.O; } else { whichPiecePlaysNext = Piece.X; } } 
    submitted by /u/esotericnumeric
    [link] [comments]

    I need to try to find the highest score out of all the students and output it

    Posted: 30 Aug 2018 07:40 PM PDT

    x = 30 names = [""] * x test1 = [-1] * x test2 = [-1] * x test3 = [-1] * x total = 0 temp = 0

    for i in range(x): names[i] = input("What is the name of the student, ")

    while test1[i] < 0 or test1[i] > 20: test1[i] = int(input("What is the student's score for the first test"))

    while test2[i] < 0 or test2[i] > 25: test2[i] = int(input("What is the student's score for the second test"))

    while test3[i] < 0 or test3[i] > 35: test3[i] = int(input("What is the student's score for the third test"))

    total = test1[i] + test2[i] + test3[i]

    print(names[i],"'s total score is", total)

    temp = test1[i] + test2[i] + test3[i] + temp

    average = temp/x

    print(average)

    I have all the indents dont worry, it's just hard formatting in reddit.

    This is my current code and I already found out the average which was a previous question. I now need to figure out how to get the highest score from the array and output it. Please put it as simply as possible so I can understand it, thanks a lot :)

    submitted by /u/HeyItzZach
    [link] [comments]

    Excel drop down list, need help doing more than one cell!

    Posted: 30 Aug 2018 07:37 PM PDT

    Hello everyone, I've created a drop down list in excel for my fantasy football league using this guide:

    https://www.youtube.com/watch?v=vkPoViUhkxU

    TL:DW is make a reference that searches a specific cell for text, cross-references a list, then creates a smaller list of the words that match the written text in the search cell. Relevant lines of code are as follows:

    =IF(ISNUMBER(SEARCH(Sheet4!$A$7,C2)), MAX($B$1:B1)+1, 0)

    =IFERROR(VLOOKUP(ROWS($E$2:E2),B2:C301, 2,0), "")

    =COUNTIF(E2:E301,"?*")

    Name Manager =OFFSET(Sheet3!$E$2,,,COUNTIF(Sheet3!$E$2:$E$303,"?*"))

    Then use data validation to make a drop down list from the name manager. However, I need to do this for 170 cells, and I was wondering if there was a workaround rather than copying and pasting 170 times. I need to change the reference cell each time, as well as the lookups and offsets.

    Also 110% open to redoing it an easier way if you know a better way! Thanks for reading my post any help is appreciated

    submitted by /u/triplechin5155
    [link] [comments]

    [ C++ Question ] Why am I getting a ('Birthday': 'class' type redefinition) error?

    Posted: 30 Aug 2018 07:24 PM PDT

    The error points to line 3 of birthday.h

    Something tells me it's a BS compiler error and I'm messing up somewhere else. If you help me solve this, you are a god. This little baby project is from this video : https://www.youtube.com/watch?v=jCaxfmcDYjs&t=303s

    main.cpp

    #include <iostream> #include "People.h" #include "Birthday.h" using namespace std; int main() { Birthday birthDayOfGus(3, 4, 1999); People gus("Marcus", birthDayOfGus); gus.printInfo(); system("pause"); return 1; } 

    birthday.h

    class Birthday { public: Birthday(int m, int d, int y); void printDate(); private: int month; int day; int year; }; 

    birthday.cpp

    #include <iostream> #include "Birthday.h" using namespace std; Birthday::Birthday(int m, int d, int y) { month = m; day = d; year = y; } void Birthday::printDate() { cout << month << "/" << day << "/" << year << endl; } 

    people.h

    #include <string> #include "Birthday.h" using namespace std; class People { public: People(string x, Birthday bo); void printInfo(); private: string name; Birthday dateOfBirth; }; 

    people.cpp

    #include <iostream> #include "People.h" #include "Birthday.h" using namespace std; People::People(string x, Birthday bo) : name(x), dateOfBirth(bo) { cout << "This is the people constructor here!" << endl; } void People::printInfo() { cout << name << " was born on " << endl; dateOfBirth.printDate(); } 

    submitted by /u/DietDonut
    [link] [comments]

    I don't want to give up but I need advices

    Posted: 30 Aug 2018 07:18 PM PDT

    Hi everyone, first of all, english is not my first language, sorry if I make any mistake. Currently I'm taking an annual course of "Algorithms and Data Structure", it's supposed to be an easy course. But the professor is messing up the class (IMO), he is giving us content that other professors don't touch at all. What I mean is that the contents of the course are basically Conditionals, Structs, Pointers, Functions, Data Structure in general, Arrays, Files, etc. But this professor is giving us things such as Templates and some exercices from advanced algorithms. My point is that all this things are pretty much overwhelming me.

    Any advice on how to study "complex" things such as templates, abstract data types and this things? I need tips more than resources. I don't want to lose my annual course. Thanks in advance.

    submitted by /u/venganzz
    [link] [comments]

    No comments:

    Post a Comment