while (true) {

Status
You're currently viewing only Zich's posts. Click here to go back to viewing the entire thread.

Zich

Ars Tribunus Militum
2,872
Subscriptor++
LordHunter317":3yp5hmao said:
It's not uncommon to write code that way, but compile it is a completely different story.

This brings up an interesting tangential point. If I'm writing a large amount of new code, I've always had the habit of compiling it at incremental steps. This seems like the only sane thing to do to me. But perhaps that's a stylistic difference, and why some people don't have these sorts of issues.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Oh certainly it's worth it. But this makes a whole lot of assumptions that really can't be applied universally. Plenty of people are not in a position in their life where they can just change jobs on a whim. Nor is it really reasonable to think someone would change jobs because of version control.

And, though it may be hard to understand for some people, not everyone is willing or able to take a leadership role. It really shouldn't be a negative mark on a person if they're unwilling to be a flaming extrovert and shove their vision down people's throats.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Blacken00100":2tubfgys said:
Relatively few worthwhile developers are in a position where they must put up with drudgery if they don't choose to. Stay out of flyover country and keep up with your skills and you're not likely to hurt for work now or in the medium-term future.

This still makes rather sweeping generalizations, though. I've known lots of awesome programmers with great lives and families in "flyover country". Why abandon all that because of a few silly suboptimal things at a company?
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Another thing to keep in mind about DVCS is that there are definitely industries that it isn't very practical for. For example, I worked in the game industry for 7 years or so, and a single snapshot of the repository for newer games can be 100+GB, since all the art assets need to be versioned with the source. Though this situation seems to be improving with some DVCS giving more thought to shallow checkouts of binaries.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
I'm looking for the proper term for a UI widget. What would you call the "timeline" in media players that you can click around on to move between various points of a video? The best thing I can think of is "scrubber" and "timeline", but my googling is failing me.

To be more specific, I'm working on implementing something like this, except where data is still coming in as the user is scrolling through existing data. The closest analogy is probably time shifting a live TV program. There are some implementation details to work out, especially regarding positioning of the current time indicator when it's being dragged as more data is streaming in.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Basically, the last couple of posts have hit on my dilemma, which is why I'm trying to do some more research on how other people have solved this. It's conceivable that a large amount of data could come in while the user is scrubbing around.

I think I would need to treat it as if the new data doesn't exist from a scaling perspective while the user is actively dragging around. Then re-scale when they release. Though that would then cause a jump in positioning out from under the cursor on release. Which is odd.

Or come up with a completely different way of cycling through the data, which escapes me.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
I suppose I could go into a little more detail. I'm working on a memory profiler with a heavy emphasis on visual representation of memory layout over time. So the "data" here is largely information about memory allocations. The use case is someone seeing something "interesting" in the profile as the target application is running, and wanting to check it out while continuing to collect data.

It may be that most people just want to collect a profile run and analyze it later. But I've built the tool from the start to be able to deal with the data in real time, which has required being very careful about time complexity of its various algorithms. I think this is a good selling point.

The eventual plan (which - somewhat frighteningly - is quickly approaching v0.1) is to sell it via a MicroISV-type setup. Perhaps I'll post more sometime post-launch to share about its success/failure.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Here's one I was recently asked. Apparently, I actually did better than I thought, as I'm going to the next round. The problem is really quite simple, but there's a linear-time solution that just wasn't popping into my head.

Given a tree where each node only contains a pointer to its parent, find the first common ancestor for any two arbitrary nodes.

Part of my hang up was that I was trying to think about lots of complicated trees, when the problem actually boils down to two lists converging. The main issue is dealing with finding the point of convergence without storing extra information or doing an n^2-type loop. If the two given nodes are at different heights in the tree, you can't simply walk up the tree and expect to get a collision. Visualized:

Code:
    1
    2
    3
   4 5
   6 7
   8

Once you know the obvious solution, it is obvious. You need to measure the height of both nodes by walking all the way up for both of them. Then you "trim up" the longer tail so its height matches the shorter one. Then walking them up side-by-side will produce a guaranteed collision.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
If I understand your solution correctly, it would look like this (in C-flavor pseudocode)?:

Just with a cursory scan of your solution, that looks right. The actual code, unfortunately, is the easy part. It's lucking out and getting that eureka moment that's the issue for me. Especially in the time constraints and stress of an interview situation.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
Gawd I hate this stuff SO MUCH.

If you're going to document something, then DOCUMENT IT ACCURATELY.

In a record limit field: The tool tips says In a "Blank = ALL"

Operation runs and does not return the data set expected.

Dig for a while, oh, Blank = 100 fucking records.

I actually want to go back to Notes. At least in that environment ALL = ALL and not some arbitrary number hidden in the background to try to save me from myself.

Agreed! Much better to just not document anything.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
I spent years trying to figure out why Windows 10 was snappy on some machines and hideously slow on others. The miracle cure ended up being the first fix on this page about disabling Cortana: https://windowsreport.com/file-explorer ... indows-10/

Sounds crazy, but I've done that on multiple machines now and it makes a massive difference.
 

Zich

Ars Tribunus Militum
2,872
Subscriptor++
So the next step would be a technical interview. We understand that most developers don't deal with computer science fundamentals on a day to day basis so we recommend spending some time getting back up to speed before scheduling the interview. We'll send you some resources to look at, and you can always go through leetcode.

The fact that they say this is proof that their interview process is broken.
 
Status
You're currently viewing only Zich's posts. Click here to go back to viewing the entire thread.