Vote count: 0 I'm still trying to grasp an intuition of pullbacks (from category theory), limits, and universal properties, and I'm not quite catching their usefulness, so maybe you could help shed some insight on that as well as verifying my trivial example? The following is intentionally verbose, the pullback should be (p, p1, p2), and (q, q1, q2) is one example of a non-universal object to "test" the pullback against to see if things commute properly. -- MY DIAGRAM, A -> B B f x = (x, True) g :: C -> B g x = (1, x) -- PULLBACK, (p, p1, p2) type PL = Int type PR = Bool type P = (PL, PR) p = (1, True) :: P p1 = fst p2 = snd -- (g . p2) p == (f . p1) p -- TEST CASE type QL = Int type QR = Bo...
ادامه مطلبVote count: 0 Just wanted to run this by some experts and get their thoughts on it. The way I am doing it just feels kinda hacky. Here is my code:: Basically I find the Groups that the user is a Member of, then search for the group(s). As you can see I run a for loop that retus the object of each different group. That all works, but the problem is it seems like a lot of querying, and the callback function for some reason runs before the code is done executing. var query = firebaseApp.database().ref().child('members').orderByChild('uid').equalTo(testUID); query.once('value').then(function(snapshot) { snapshot.forEach(function(childSnapshot) { userObject = childSnapshot.val() userGroups = user...
ادامه مطلب