• Activity
  • Votes
  • Comments
  • New
  • All activity
    1. What are your unsolved programming problems?

      I thought it could be fun to discuss problems that we've encountered in our programming or programming-related work and have never found a solution for. I figure that at worst we can have a lot of...

      I thought it could be fun to discuss problems that we've encountered in our programming or programming-related work and have never found a solution for. I figure that at worst we can have a lot of fun venting about and scratching our heads at things that just don't make any sense to anyone, and at best we might be able to help each other find answers and, more importantly, some closure.

      16 votes
    2. ~comp book club: Site Reliability Engineering, chapter 1

      For the first book of this book club, I chose Google's book on Site Reliability Engineering, because it's freely available online, so we can get started without waiting for any dead-tree books to...

      For the first book of this book club, I chose Google's book on Site Reliability Engineering, because it's freely available online, so we can get started without waiting for any dead-tree books to arrive. For the next book I'll plan on a few weeks lead time to decide on a book then acquire it from whatever bookstore or library you use.

      I'm going to aim to do this every Thursday, 1 chapter per week (or maybe 2, if they're short?)

      Today's reading: Preface and chapter 1 (full list of chapters here)

      12 votes
    3. Let's talk about tooling.

      Hey! Since it's a small community at the moment, I think we can have a very genreral thread about anything regarding tooling: interesting technologies you use at work/home, your editor, plugins,...

      Hey! Since it's a small community at the moment, I think we can have a very genreral thread about anything regarding tooling: interesting technologies you use at work/home, your editor, plugins, themes, bruh let's even share some screenshots. I find this kind of shit exciting and know more people like me exist out there :)

      13 votes
    4. Website Admin Question: How to Block Google?

      I have a personal website, and while I don't mind it showing up in SERPs for DuckDuckGo, Bing, etc. I do not want it showing up on Google at all. Google doesn't send traffic my way, I pay for my...

      I have a personal website, and while I don't mind it showing up in SERPs for DuckDuckGo, Bing, etc. I do not want it showing up on Google at all.

      Google doesn't send traffic my way, I pay for my site out of my salary from my day job instead of running ads, and preventing Google from indexing my site seems like the best form of nonviolent direct action I can take to protest their continuing dominance and their "embrace, extend, and extinguish" campaign against the Web.

      I figure the easiest way to do this is to add the following to my site's .htaccess file since I don't have access to the server config file:

      X-Robots-Tag: googlebot: none, noarchive, nosnippet, notranslate, noimageindex
      

      Are there any downsides that I should know about besides not showing up in Google results?

      11 votes
    5. Inexperienced Programming Question

      TLDR: What programming language would be useful for taking info in an excel file and producing a text file (that is organized and arranged in a particular way) containing that info? Which would be...

      TLDR: What programming language would be useful for taking info in an excel file and producing a text file (that is organized and arranged in a particular way) containing that info? Which would be useful for this problem but also helpful in general? And also, are there any recommended online courses where I could learn it?


      I have no real experience coding or anything but have always wanted to learn. Recently at work we've encountered a problem. My boss had created a matlab program in order to take text/numbers from an excel document and transfer them to a text file, but in an organized way.

      Say you have something you call "Pancakes" and the cell next to it has the number "3", as in there are three pancakes. I want to be able to create a text file that would read something like this:

      NUMBER OF PANCAKES

      • Pancakes: 3

      We recently have changed around the format of the excel document for a different item, for example "French Toast". I've tried to mess with matlab briefly but was unable to change the program to compensate, and I no longer easily have access to matlab.

      I'm seeing this as an opportunity to learn some programming and also fix some stuff at work. So what programming language would be useful for fixing this problem? Which would be useful for this problem, but also helpful in general? And also, are there any recommended online courses where I could learn it?

      Thanks for any help, I appreciate it.

      16 votes
    6. Rubber Duck just saved me. What about you?

      To put this into context: I'm still minor, in Europe, and I was hired into SW company as backend developer. I'm making about 2-3 times as much as my friends in fastfoods. I'm basically making WS...

      To put this into context: I'm still minor, in Europe, and I was hired into SW company as backend developer. I'm making about 2-3 times as much as my friends in fastfoods.

      I'm basically making WS that would be unified wrapper for about 15 another WS - instead of crafting request for each of those, you will just call the API and it will do everything for you.

      Everything was fine, until I encountered a nightmare: WSDL/SOAP protocol over HTTPS with need to use client certificate.

      Full of false hope, I thought: "It'll be easy, I finished communication with another companies in few hours, this will be quick".

      I was very wrong. I spent countless hours on this. I tried 3 programming languages and 4 different frameworks, copy-pasting solutions from stack overflow and wondering why does this still throw errors! I copied it from stack overflow! I used windows alongside linux and installed like 10 wsdl/soap clients from 2008 forums.

      I created 8 or so SO questions, most about different language/framework, but the same problem.

      Worth of mentoining, at the time, I could obtain wsdl and xsd of the WS with usage of two certificates (crt.pem and key.pem) over PHP. I tried to use PHP SoapClient, which accepted just one certificate file. I used .pem certificate that I received and should get the work done.

      Then, I started writing the final question. Including PHP that downloaded wsdl and SoapClient that didn't work. Knowing someone will probably want to see certificates, I used cat key.pem cert.pem > certCombined.pem and diff certCombined.pem cert.pem. cert.pem was the certificate I received and should work. I expected no differences. When I saw two pages of differences, I started to suspect the cert I was given is wrong. So I pointed the PHP SoapClient to certCombined - and it started working!

      This would have never happened (at least for several more hours) unless I known someone will want to see diff between working and not-working certificates. Thank you, rubber duck debugging! Next time I'll be solving something, I'll write on paper everything I use and know.

      What are your stories?

      13 votes
    7. What conferences are on your wish list? (for team leads or wannabee managers)

      Imagine that your boss told you that the company is happy to send you to one or two conferences next year, with the aim of helping you to improve your leadership skills. In this context,...

      Imagine that your boss told you that the company is happy to send you to one or two conferences next year, with the aim of helping you to improve your leadership skills.

      In this context, "leadership" includes Culture; Coaching & Mentoring; Teamwork; Continuous Improvement; Collaboration; Agile; Culture Change.

      You want to make a list of conferences worth considering in order to estimate the budget. What events would you put on your list?

      7 votes
    8. Programming Challenge: Make a game in 1 hour!

      Background There's been some talk on ~ before, and it seems like there are quite a few people who are either interested in, learning, or working in game development, so I thought this could be a...

      Background

      There's been some talk on ~ before, and it seems like there are quite a few people who are either interested in, learning, or working in game development, so I thought this could be a fun programming challenge.

      This one is fairly open-ended: make a game in 1 hour. Any game, any engine, don't worry about art or sound or anything.

      Doing is the best way to learn. Most people's first project is something overly ambitious, and when they find that it's more difficult than they thought, they can get discouraged, or even give up entirely. This is why the 1 hour limit is important: it forces you to finish something, even if it's small. When you're done, you can come out of it saying you made a game, and you learned from it.

      Chances are the game might not be fun, look bad, be buggy, etc. But don't worry about that, everyone's game will have problems, and if you do create something really fun or innovative, congratulations, you have a prototype that you can expand on later!

      "Rules"

      Like I said before, these "rules" are pretty simple: make a game in (approximately) 1 hour. You can use any tools you want. If you use external assets (art, sound), it's probably best you use something you have the rights to (see resources). If you're completely new to game development/programming, your goal could even be to finish a tutorial.

      If you're the kind of person who tends to get carried away with these things, you might want to post a comment saying you're starting, then another one once you've finished your game.

      Please share your finished game, I'm sure everyone would love to try them! If your game is web-based, it can be hosted for free on Github Pages or Itch.io. If downloadable, it can be hosted for free on Google Drive, Mega, Dropbox, Itch.io, etc.

      Resources

      Engines

      If you're a beginner, a good engine to start with is LÖVE. It's very simple, and uses Lua, which is very easy to learn.

      If you're familiar with another language, you could use a library to make it in that language. Some examples:

      C++: SFML, SDL, Allegro

      Javascript: kontra, Phaser, pixi.js

      Python: pygame

      Rust: Piston, ggez, Amethyst

      If you want something more complex, consider Godot, Unity, or Unreal.

      You can also try something visual like Construct, Clickteam Fusion, or GDevelop

      Art

      For such a short time constraint, I'd suggest you use your own "programmer art": just use some basic shapes. Your primary focus should be gameplay.

      If you think you have time to find something, try looking on OpenGameArt.

      Sound

      You can make simple sound effects very quickly with sfxr (or in this case, a web port of sfxr called jsfxr).

      27 votes
    9. Now that Ubuntu 18.04.1 is out, have you upgraded from 16.04 LTS?

      The first point release came out July 26, and enables upgrades from 16.04 LTS. https://blog.ubuntu.com/2018/07/26/first-point-release-of-18-04-lts-available-today Have you upgraded your desktop?...

      The first point release came out July 26, and enables upgrades from 16.04 LTS.

      https://blog.ubuntu.com/2018/07/26/first-point-release-of-18-04-lts-available-today

      Have you upgraded your desktop? Server?

      Happy with it? Any pitfalls?

      20 votes
    10. Discussion: The pros and cons to different approaches to solving a problem.

      It's often the case that in academic and self-teaching environments, you don't really have the opportunity to grasp and fully understand situations in which a problem has multiple valid solutions...

      It's often the case that in academic and self-teaching environments, you don't really have the opportunity to grasp and fully understand situations in which a problem has multiple valid solutions and what the implications are in choosing among them. Among those considerations are two in particular: runtime efficiency and maintainability. When these subjects are discussed, the example solutions are often comical at best, or the problems themselves too complex to fully grasp the situation at hand. Sometimes the problems are also so simple as to be completely worthless, e.g. comparing bubble sort to bogo sort.

      As such, I would like to take this opportunity to discuss practical but conceptually simple problems and the implications of the different solutions that are available. Conceptual simplicity is an absolute requirement because we want these problems to be accessible to a wider variety of readers. Problems don't necessarily need to be code-related (you could e.g. discuss something related to server administration). Bonus points for problems that include solutions with an efficiency/maintainability trade-off!

      9 votes
    11. Learning to Program

      Hi folks, I figured this would be a good place to ask a rather simple question. Where do I start to learn to code? I'm in high school, so I have (some) time to dedicate to it, and it seems there...

      Hi folks,

      I figured this would be a good place to ask a rather simple question.

      Where do I start to learn to code?

      I'm in high school, so I have (some) time to dedicate to it, and it seems there are a plethora of websites/resources out there, so I ask: what do you recommend, and why has it worked for you? I have no prior experience. I believe that this would really help out in the long run, as I will graduate high school with an Associate's Degree in Business. Thank you!

      EDIT: Thank you for all your responses! I'll start with Python and move on from there. You guys have been a great help, and I'll vote you up or reply.

      26 votes
    12. Programming Mini-Challenge: TicTacToeBot

      I've seen the programming challenges on ~comp as well as quite a few users who are interested in getting started with programming. I thought it would be interesting to post some 'mini-challenges'...

      I've seen the programming challenges on ~comp as well as quite a few users who are interested in getting started with programming. I thought it would be interesting to post some 'mini-challenges' that all could have a go at. I'm certain that many of you might find these pretty straight forward, but I still think there's merit in sharing different approaches to simple problems, including weird-and-wonderful ones.

      This is my first post and I'm a maths-guy who dabbles in programming, so I'm not promising anything mind-blowing. If these gain any sort of traction I'll post some more.

      Starting of with...


      TicTacToeBot


      Info

      You will be writing code for a programme that will check to see if a player has won a game of tic-tac-toe.


      Input

      The input will be 9 characters that denote the situation of each square on the grid.

      • 'X' represents the X-player has moved on that square.
      • 'O' represents the O-player has moved on that square.
      • '#' represents that this square is empty.

      Example:

      |O| |X|
      |X|X|O|    The input for this grid will be O#XXXOO##
      |O| | |
      

      Output

      The expected output is the character representing the winning player, or "#" if the game is not won.

      (e.g. The expected output for the example above is '#' since no player has won)


      29 votes