Looking for or to create a logic of < or > - app-inventor

In AppInventor2 we drag logic down there is = , not = , and, or, but I can't seem to find the greater or less than logic. Can anyone enlighten me?

see the documentation of the math blocks in App Inventor 2

Related

Add sample names to s.class

So I'm trying to add sample names to my PCA s.class. Someone here (on another question) suggested adding text() to it, but I can't seem to figure out how to align the two.
Here is my code:
s.class(pca1$li, fac = beardata$pop, xax=1, yax=2)
add.scatter.eig(pca1$eig[1:20], 3,1,2, pos="bottomright", inset=.01, ratio=.18)
first code image
s.class(pca1$li, fac = beardata$pop)
text(pca1$li,labels=indNames(beardata),cex=0.7)
add.scatter.eig(pca1$eig[1:20], 3,1,2, pos="bottomright", inset=.01, ratio=.18)
This is what I get with added text()
Thank you for any help, I'm quite new at this so I hope this has easy solution.

Separating index values from an array inside discord embed

I'm looking for a way to spit out an embed that lists all the "suggestions" in my database with their corresponding index values like this. So far I can send an embed with all of the information like this but that just adds the information as 2 strings after each other (suggestions then the index values).
I need a way to display the "suggestions" in the embed with the index values separately like this:
[#1] suggestion 1
[#2] suggestion 2
[#3] suggestion 3
[#4] suggestion 4
Ideally this would all be done within one embed field.
I'm sorry if this was poorly worded but if I knew how to describe what I'm looking for, I might have found the answer sooner. Thanks for any advice in advance.
(I'm using the replit database - if any more of the code is needed please let me know)
#client.command()
async def suggestions(ctx):
suggestions = []
if "suggestions" in db.keys():
suggestions = db["suggestions"]
joined = '\n'.join([str(elem) for elem in suggestions])
index_number = '\n'.join([str(i) for i in range(len(suggestions))])
channel = client.get_channel(0000000000000)
suggestionsEmbed=discord.Embed(title="Server Suggestions", description="Vote for suggestions with **$vote #** Remove suggestions with **$del #**", color=0x15e538)
suggestionsEmbed.set_thumbnail(url="https://www.startup.pk/wp-content/uploads/2020/07/ideaideabulblightbulbicon-1320144733751939202.png")
suggestionsEmbed.add_field(name='Suggestions Created', value=f'{joined} **#{index_number}**')
await channel.send(embed=suggestionsEmbed)

Using IF, AND/OR (many condition) with Array formula in Google sheets

Could someone help me?
I'd like to use the Array formula with AND/OR as follows but it doesn't work
=ArrayFormula(if(AND(AG2:AG="Yes",AI2:AI<>""),"Ok","Blank"))
It similar to OR
How can I use this in case I need to put more than 2 conditions in the AND/OR when using the Array formula?
Thanks so much.
Do not use AND/OR with ARRAYFORMULA, use + instead of OR and * instead of AND with IF
Try
=ArrayFormula(if((AG2:AG="Yes")*(AI2:AI<>""),"Ok","Blank"))
You can add other conditions if you respect the syntax with + or *

Laravel- Due in the next 6 months using Carbon submonths

I am trying to relieve data from my database that will only return data that will be due in the next 6 months.
In my controller, this is how I query my database.
$critical = infrastructure::where("inf_lifspan",">", Carbon::now()->subMonths(6))->get();
The results is shown below.
Can someone point me in the right direction what I did wrong?
Thanks.
Thanks guys, I got the answer. I just need to change the > sign to < sign.
$critical = infrastructure::whereDate('inf_lifspan','<', Carbon::now()->addMonths(6))->get();

Descendent-or-self in InfoPath

I want to use XPath code in an InfoPath form to sum the data in field12 when field11 is equal to IT. I tried using the following code, but it doesn't work.
number(sum(/descendant-or-self::node()/my:group12[my:field11 = "IT;"]/my:field12))
I suspect this has to do with the multilayering of groups, as shown below. Does anyone know the code that would allow me to get to the data in group12? Thanks in advance for your help.
myfields>group9>group10>group11>group12>field11 field12
Genipro
Looks like:
number(sum(/descendant-or-self::my:group12[my:field11 = 'IT;']/my:field12))
could be right.
decendant-or-self should not be necissary in this case (unless you need the expression to work even if group12 is moved).
This should work fine:
sum(/my:myfields/my:group9/my:group10/my:group11/my:group12[contains(my:field11,'IT')]/my:field12)
It doesn't matter if any of the other groups are repeating either. All group12's will be checked.

Resources