If there is any research on Goal Based Programming (GBP)?

The more I think about programming and optimization, the more I think “why not just specify a goal and have the program figure out the optimal solution to it”.

I am familiar with basic “optimization problems” such as finding the best fit line to a curve, or gradient descent sorts of things. What I’m talking about is way more complicated than that.

What I’m imagining is to say something like “An HTTPS server exists”, and for the system to figure out how to build one. Obviously given just that info, it’s not enough. It would require human-level training in programming and understanding concepts and everything.

But my question is, what could you do to build a system to support such a “goal statement”? What would the key parts be?

It seems at first, the simplest goal is “Action x is performed”. This is required to change the current world into the desired (goal) world. For example, "Add" is performed on 1 and 2 is a goal stating that the “add” function is applied to the two arguments. It seems that from this foundation, you can build up higher and higher levels of abstraction to the point where you could then say “An HTTPS server exists”. But this HTTPS server is a structure, not an action. So you need some way to have some intermediate goals that transcribe goals into (not actions, but) structures. Perhaps, The result of x operation exists is a simple transformation between the two.

But then I’m stuck haha. What do the goals look like in the intermediate realm? Has anyone done any research into this area? Searching doesn’t yield much, though it brings up a book Goal programming and extensions which I might have to purchase.

extract only single value from multiple rows based on certain condition for same id in Oracle

I’m oracle beginner, and I’m having trouble shooting the below issue –

My table is –

+——-+——+——-+—— + | ID | GRP | ITDESC| DEN |
+——-+——+——-+—— + | 12345 | MANX | Apple | SendV | +——-+——+——-+—— + | 12345 | MANX | Apple | Manual| +——-+——+——-+——- | 12345 | MANX | Apple | UnVeri| +——-+——+——-+—— + | 12346 | MANX | Mango | UnVeri| +——-+——+——-+—— + | 12347 | MANX | PineAp| SendV| +——-+——+——-+—— + 12348 | MANX | Pine | Manual|

I am expecting –

+——-+——+——-+—— + | ID | GRP | ITDESC| DEN |
+——-+——+——-+—— + | 12345 | MANX | Apple | SendV | +——-+——+——-+—— + | 12346 | MANX | Mango | UnVeri| +——-+——+——-+—— + | 12347 | MANX | PineAp| SendV| +——-+——+——-+—— + | 12348 | MANX | Pine | Manual| +——-+——+——-+—— +

I have multiple rows that has only the DEN column different for the same id. My aim is – for the same id perform the check – If the Value of DEN is ‘Manual’ then check to see if there is ‘SendV’ in DEN column for that id. If it is present then consider ‘SendV’ otherwise consider ‘Manual’. Note in the provided example, the order is a random, the SendV can be in 2nd row or 3rd row or 4th row based on the action, however the text of DEN will be same as said above.

select * from table t1 where DEN IN (‘Manual’, ‘SendV’) .I am not aware how to write the condition??

Any suggestions/oracle query help is welcome.

Are there any reasons for Kerberos being based on symmetric cryptography?

Kerberos is an authentication protocol that is famously built using only symmetric ciphers.

As a direct result of this, there are several attacks possible, such as

  • AS-REP Roasting
  • AS-REQ Roasting
  • Kerberoasting
  • Silver Tickets
  • Golden Tickets

While some attacks require specific conditions (e.g. AS-REP Roasting requires disabling pre-authentication), other attacks like AS-REQ Roasting cannot be prevented at all.

It seems odd to me to use symmetric cryptography for a task that just screams “Please use asymmetric cryptography for this!”. Is there something I am missing? What are the reasons for choosing symmetric ciphers?

Is there a way to have Shadow Hand save DCs based on Charisma?

I am playing a Spellthief/Rogue and just picked up the Martial Study feat to gain access to Shadow Hand maneuvers. Shadow Hand is a Swordsage-exclusive school and its maneuvers key off Wisdom for their save DCs, but as a Spellthief, I boosted my Charisma and my Wisdom is pretty low.

Is there any way to change my Shadow Hand maneuver’s save DCs to key off Charisma instead of Wisdom?

algorithm for scheduling tasks based on constraints and feedback loop if possible

I have a list of recurring tasks (1k+ tasks) and I am trying to find a optimal scheduling given a shared constrained resource.

In other respects the tasks are independent of each other

Each task is configured to run recurrently at a given interval (i.e “cron” job). For instance a particular task could have been configured to run at 10 minute intervals while another task could be configured at 20 minutes etc.

The duration of tasks varies (disregarding the shared resource)

Tasks have priorities (importance).

The task interval is in respects to the completion time of the previous run.

Task interval is “soft” and can be offset to accommodate for higher priority jobs.

I can estimate based on historical evidence how many “shares” of the shared resource each task requires

+-----------+-------------+----------+--------------------+-------------------------+ | Task name |  Interval   | Priority | Estimated duration | Estimated resource      | +-----------+-------------+----------+--------------------+-------------------------+ | task1     | 30 minutes  |        1 | 10 minutes         | 10                      | | task2     | 10 minutes  |        3 | 25 minutes         | 90                      | | task3     | 60 minutes  |        4 | 5 minutes          | 25                      | | ...       |             |          |                    |                         | | task 1000 | 180 minutes |        2 | 75 minutes         | 100                     | +-----------+-------------+----------+--------------------+-------------------------+ 

conceptually the architecture should be:

                                                                              +------------+   task list                                                                   |            | +-------------+                                                               | Task x     | |             |                       +-----------+                           |            | |    Task1    |                       |           |      running  tasks------>+            +----------+      +-----------------+ |    Task2    |    choose tasks       |           |               |           |            |          |      |                 | |    Task3    +----------------------->  Scheduler+---------------+           |            |          |      |                 | |    ....     |                       |           |               |           +------------+          |      |                 | |    Task_N   |                       |           |               |               .                   +----->+                 | |             |                       |           |               |               .                          | constrained resource |             |                       +-----------+               |               Many tasks                 |                 | |             |                                                   |               .                   +------>                 | +-------------+                                                   |               .                   |      |                 |                                                                   |           +------------+          |      |                 |                                                                   |           |            |          |      |                 |                                                                   |           | Task z     |          |      +-----------------+                                                                   +----------->            +----------+                                                                               |            |                                                                               |            |                                                                               |            |                                                                               +------------+ 

Using conditional logic on fields in gravity form based on Paid Memberships Pro membership level

I’m trying to use conditional logic to hide/show fields in my gravity form based on user’s membership level determined by Paid Memberships Pro. I’ve tried all different variations using {user:membership_level} in a hidden field. Then, using conditional logic on selected fields, I’ve tried to hide/show based on the value of the membership level.

Any help would be appreciated. Is my meta key ({user:membership_level}) incorrect?

Making groups out of a list of things based on some similarity

Let’s say I have a list of n items – i1, i2, …, in.

These items are similar to one another based on some similarity function, say similar_func(item_x,item_y) where item_x,item_y belong to list i1, i2, … in. This function returns a number that ranges from 0 to 1, where 0 means not similar at all and 1 means exactly similar.

Now I would like a create a number of groups, each of which may contain items from the above list. Each group having items that are similar to each other items of the group by let’s say 0.5.

I could run a double loop on the list, comparing each item to one another and creating a group whenever I find two items with similarity more than 0.5. Of course I would need to check if the item already exists in a group already created and with all the other items in that group.

This brute force method is possible and will give the right answer.

But I would like to do this more efficiently. Is there a efficient method for solving this problem?

Edit: There can be any number of groups and an item can be in multiple groups.

If similarity(x,y) = 0.6 and similarity(x,z) = 0.6, but similarity(y,z) = 0.4, then there will be two groups -> [x,y] and [x,z]

Also if x is similar to y AND x is similar to z, then it doesnt mean that y is similar to z. The similarity between two items solely depends on the the return value of similarity function when those items are passed as arguments to it.

Managing pre-placed objects in a grid based game

i am building a city management 3D game, however the terrain is completely flat. I am planning to use a grid for placing roads and walls and buildings.

It then makes sense to use the grid to detect where you can build instead of colliders.

My question is, how do I get the pre-existing objects like trees, rocks etc on my grid so that I can’t place buildings on top of them? Or is there a better way?