Information Technology

C Programming Matrix values getting corrupted??

Learn Programming - Thu, 11/15/2018 - 18:09
#include <stdlib.h> #include <stdio.h> int main() { int rows, columns, i, j, k, n; int matrix[10][20]; printf("Enter number of rows "); scanf("%d", &rows); printf("Enter number of columns "); scanf("%d", &columns); for(i=1; i<rows+1; i++) { for(j=1; j<columns+1; j++) { for(k=1;k<=1;k++) { n = rand() % 10; n = matrix[i][j]; } } } for(i=1; i<rows+1; i++) { for(j=1; j<columns+1; j++) { printf("%d\t", matrix[i][j]); } printf("\n"); } }

It keeps returning some random numbers like 35769 or some bs like that. Help? The matrix is supposed to fill with random numbers from 0-9 and be printed. Number of rows and columns specified by user.

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

Looking to buy a gaming laptop $900 maximum budget

Hey guys! I've been looking for a while now, for a brand new laptop and I really like the Asus rog Hero edition, would this be a good purchase? I'm aware that black Friday is upon us so I wanna take advantage of that! My budget is between $700 and 900$

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

Any suggestions for IT student

  • Total budget and country of purchase: $1000-2100, Norway
  • Do you prefer a 2 in 1 form factor, good battery life or best specifications for the money? Pick or include any that apply. don't care for 2 in 1 at all. Good battery life is a must(6h+ if possible). Spec for price is important
  • How important is weight and thinness to you? want a thin laptop (like razer blade or Dell XPS but they're too expensive)
  • Which OS do you require? Windows, Mac, Chrome OS, Linux. Win 7-10 (want to learn some Linux as well)
  • Do you have a preferred screen size? If indifferent, put N/A. 14-15"
  • Are you doing any CAD/video editing/photo editing/gaming? List which programs/games you desire to run. I’d like to use it for coding in the future as well as being used for work and games like GTA V or Prison Architect
  • If you're gaming, do you have certain games you want to play? At what settings and FPS do you want? looking to get at least 60fps+
  • Any specific requirements such as a good keyboard, reliable build quality, touch-screen, finger-print reader, optical drive or good input devices (keyboard/touchpad)? Optimally a good gaming laptop with a backlit keyboard and the USB type A and C input as well as HDMI or VGA.
  • What laptops have you been looking at? mainly the little too expensive laptops like Razer Blade . Dell XPS 15 and MS Surface laptop (-doesn't have dedicated graphics card)
submitted by /u/Dexy2811
[link] [comments]

Tutorial: Make a Real-Time Chat App with Action Cable & React

Learn Programming - Thu, 11/15/2018 - 18:02

Hey all,

For those who aren't familiar, React is a popular JS framework and Action Cable integrates WebSockets into a Rails app. To quote the RoR guide, Action Cable:

"...allows for real-time features to be written in Ruby in the same style and form as the rest of your Rails application, while still being performant and scalable. It's a full-stack offering that provides both a client-side JavaScript framework and a server-side Ruby framework. You have access to your full domain model written with Active Record or your ORM of choice."

Learn how to create your own chat app

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

What is "pip install --upgrade x" used for?

Learn Programming - Thu, 11/15/2018 - 18:02

I've looked at the documentation (I Ctrl+F'ed the word "upgrade" but it didn't really clear anything up) here: https://pip.pypa.io/en/stable/user_guide/#only-if-needed-recursive-upgrade

but I still don't quite get it. What's the different between doing "pip install x" and "pip install --upgrade x" (where x is the name of a package) ?

I'm asking because a package I want (specifically, PySimpleGUI) tells me to install the package using pip install --upgrade x instead of just pip install.

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

Judge rejects neo-Nazi’s First Amendment argument in harassment case

Ars Technica - Thu, 11/15/2018 - 17:55

Enlarge / Plaintiff Tanya Gersh of Whitefish, Montana. (credit: Dan Chung / Associated Press)

When Andrew Anglin isn't editing his neo-Nazi website the Daily Stormer, he organizes harassment campaigns against perceived enemies. One target of an Anglin harassment campaign, Tanya Gersh, sued Anglin last year. On Wednesday, a Montana federal judge dealt Anglin a significant setback, holding that the First Amendment does not protect Anglin's right to publish Gersh's personal information and encourage his legion of anti-Semitic followers to harass her.

But this legal battle isn't over yet. The judge's ruling allows the lawsuit to go forward, but Gersh's lawyers will still have to prove Anglin liable for invasion of privacy and other harms.

Still, the ruling could prove significant for other victims of online harassment. Anglin argued that he was just publishing information—like Gersh's home phone number—and couldn't be held responsible for what his readers did with that information. But the judge pointed to clear evidence Anglin knew exactly what readers would do with the information and egged them on at every step.

Read 14 remaining paragraphs | Comments

Why is there a terminal in PyCharm (and other Python IDEs) which resembles a Linux terminal and lets you use Linux-like commands? What exactly is it?

Learn Programming - Thu, 11/15/2018 - 17:51

Is PyCharm and any other IDE that has this feature just emulating Linux to a degree to allow you to use commands on your code/projects more easily? If so, which distribution are they emulating, seeing as commands can be different depending on the distribution. And is there a better explanation for what this is (I feel like I'm missing something)?

For example, using pip commands feels extremely similar to using commands on Linux (I'm a Python as well as Linux newbie though so I could be wrong. pip is also the only command I've ever used within this in-app terminal)

One side question I have is: which project does this terminal apply to? I've read that when you download a module using pip, it's only downloaded for your specific project instead of system wide. But my terminal doesn't seem to care which project I'm currently working on.

Any help is appreciated!

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

Anyone knows why bootstrap 4 used 1rem = 16px when they were using 1rem=10px in bootstrap3?

Learn Programming - Thu, 11/15/2018 - 17:50

Isn't 1rem = 10px recommended one, since it eases calculations? Also if someone is using bootstrap, they can't change 1rem to anything else. So I am kinda confused over the decision.

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

Apple partners with Moonlight movie studio to make feature-length films

Ars Technica - Thu, 11/15/2018 - 17:33

Enlarge (credit: Apple)

Apple has lined up another partnership to boost its video-content offerings. According to a report by The Wall Street Journal, Apple signed a deal with A24 studio, a New York-based production company responsible for movies, including the 2017 Oscar winner for Best Picture, Moonlight.

Details of forthcoming projects haven't been disclosed, but Apple reportedly signed a "multi-year partnership" to make "independent, feature-length films" with A24. Apple has numerous production partnerships and deals in the works already, but most are for serialized shows and other video content.

For the past year, Apple has focused on gleaning talent for its original content offerings. It began with the Carpool Karaoke and Planet of the Apps series, both of which are exclusively available on Apple Music.

Read 4 remaining paragraphs | Comments

Where are Python modules installed and how can I delete ones I don't use anymore (I'm using PyCharm)?

Learn Programming - Thu, 11/15/2018 - 17:33

I use the CLI in PyCharm (the one that resembles a Linux terminal) to install my modules, but I'm wondering where these are actually being installed. I'm also wondering if there's a command I can run to list all the modules I have installed, as well as delete certain modules (just so I can stay organized).

Any help is appreciated!

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

Looking for an 11-14” laptop for under $400

Hey I’m looking for a small laptop to use for work, not interested in chrome books just looking for Windows. What caught my eye was HP Stream laptop. Does anyone have any reviews on it?

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

How do I get specific information from webpage to be used in KWGT widget?

Tasker: Total Automation for Android - Thu, 11/15/2018 - 17:29

I use Goodreads to track my reading for the year. I also like to have custom widgets on my phone screen using KWGT to track my progress. What I'd love to do is to have my widget automatically update when my Goodreads updates.

Ideally, I'd like a way to get the number of books I've completed for the Goodreads challenge from my profile page. I'm completely new to tasker, is this possible?

I also have no idea how to add a tag to this post, and the edit page won't let me edit my title.

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

I want to learn python

Learn Programming - Thu, 11/15/2018 - 17:28

Does anyone know any websites to learn python for finance purposes?

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

Octolapse - New Release Available, testers wanted

3D printing news - Thu, 11/15/2018 - 17:25

I just uploaded the first stable release of Octolapse since 0.3.1, and would love some testers before it hits the plugin page (plugins.octolapse.org). If you are willing, you can install directly from the plugin manager with this url: https://github.com/FormerLurker/Octolapse/archive/v0.3.4.zip

Please post any feedback here.

Please read the release notes before installing. Octoprint 1.3.9 is required, else you'll have problems!

Any bugs discovered will have priority, and I will have time tomorrow to deal with anything you kind folks discover. I'm pretty nervous about this release since it's the first major update since the initial release. Thanks in advance for your help!

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

Facebook's CEO on his latest almighty Zuck-up: OK, we did try to smear critics, but I was too out of the loop to know

The Register - Thu, 11/15/2018 - 17:25
Mark promises independent oversight and AI as Sheryl leans far, far away

Analysis Facebook on Thursday (again) reiterated its commitment to fighting misinformation, following a report that the data gathering biz hired a public relations firm, Definers Public Affairs, to promote content that undermine company critics.…

What are some fun ways to use a linked list in a program?

Learn Programming - Thu, 11/15/2018 - 17:23

I have an assignment to make a generic linked list, and create a driver program to show it off. What are some things that a linked list would be good for in the real world? The textbook is very theory based and I have no idea what simple uses for a linked list are.

I'm not trying to make this a huge project, just trying to make the program somewhat meaningful or interesting.

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

2 in 1 for light gaming, video and photo editing

  • Total budget and country of purchase: around $1500 in Canada * Do you prefer a 2 in 1 form factor, good battery life or best specifications for the money? Pick or include any that apply. 2 in 1 style. At least an 8 hour battery life. * How important is weight and thinness to you? Not a huge consideration.* Which OS do you require? Windows, Mac, Chrome OS, Linux. Windows. * Do you have a preferred screen size? If indifferent, put N/A. At least 15" * Are you doing any CAD/video editing/photo editing/gaming? List which programs/games you desire to run. Some light Photoshop, and video editing. Not much gaming right now but would like to play PUBG and maybe rocket League? * If you're gaming, do you have certain games you want to play? At what settings and FPS do you want? Above noted games and I don't know what FPS i'd be happy with * Any specific requirements such as good keyboard, reliable build quality, touch-screen, finger-print reader, optical drive or good input devices (keyboard/touchpad)? Good touch screen. Good build quality. Pen input. Fingerprint reader. 512gb SSD drive minimum or preferably dual drives with 128gb minimum SSD and 1TB HDD. Optical drive not required but would be used if it came with it. I'd like a good quality display and sound. * Leave any finishing thoughts here that you may feel are necessary and beneficial to the discussion. Thinking of a Lenovo Yoga 730 I had an Asus Vivobook before (not a 2 in 1) and hated the poor build quality so I would like to steer clear of them.
submitted by /u/Supertooter
[link] [comments]

Pages