Discuss Scratch
- Discussion Forums
- » Suggestions
- » The Opposite of the Join Block
- PATSATDAT
-
Scratcher
1000+ posts
The Opposite of the Join Block
Support this would be useful in search engine projects
King of the page
King of the page

Last edited by PATSATDAT (March 22, 2021 11:55:31)
- Leekalo
-
Scratcher
100+ posts
The Opposite of the Join Block
mmm… semi-support. this function exists in python as find, where it will pick all the “yays” out and then you can delete them or put spaces between them or stick them into a separate variable or whatever. it's kinda useful for combing (like, I have a downloaded pdf of my physics and astronomy textbooks, and I used python to pick out all the equations and put them in a .txt file at the beginning of the school year) but I'm not sure what use it would have on scratch… it's a bit too advanced of a concept for scratch's younger audience I thinkI don't think you can modify Strings in Python, because they're immutable.
Last edited by Leekalo (March 22, 2021 13:55:56)
- warriorcats2155
-
Scratcher
500+ posts
The Opposite of the Join Block
Support, easy to implement and is very important in some projects!
- Totodile_star
-
Scratcher
500+ posts
The Opposite of the Join Block
Support THATS WHAT WE NEEDED ALL ALONG
- samq64
-
Scratcher
1000+ posts
The Opposite of the Join Block
Is this
(letters () to () of []::operators)related or is it a separate suggestion?
- the2000
-
Scratcher
1000+ posts
The Opposite of the Join Block
Is thisPretty much all that these have in common is that they're related to string manipulation. I'm not sure how you could mix them up…(letters () to () of []::operators)related or is it a separate suggestion?
- Pianostar4
-
Scratcher
1000+ posts
The Opposite of the Join Block
At first I thought it meant split it, which is impossible for computers to understand. But I must say, this is a really good idea! Support!
- gosoccerboy5
-
Scratcher
1000+ posts
The Opposite of the Join Block
Hmm, I would support this:
(I suppose this wouldn't be as intuitive as a simple delete block, but it is a bit more versatile)
replace [all v] of [] from [] with [] :: operators reporterYou can leave the first slot empty to “delete” the text.
replace [first v] of [] from [] with [] :: operators reporter
replace [last v] of [] from [] with [] :: operators reporter
(I suppose this wouldn't be as intuitive as a simple delete block, but it is a bit more versatile)
- mitdk
-
Scratcher
1000+ posts
The Opposite of the Join Block
Also,
(delete letter () of []::operators)
- CobraScripts
-
Scratcher
38 posts
The Opposite of the Join Block
Very useful, especially for the kinds of projects I make. I currently use a script like this:
set [data v] to [Splitting Strings]But a script like this:
set [firstdat v] to []
set [n v] to [1]
repeat until <(letter (n) of (data)) = [ ]>
set [firstdat v] to (join (firstdat) (letter (n) of (data))
change [n v] by (1)
end
say (firstdat) //outputs "Splitting"
set [data v] to [Splitting Strings]is so much cleaner and less annoying! I really want this as either an extention or as a new Operator block.
say (split (data) at first [ ] ::operators) //still outputs "Splitting"
- tinycoder8675
-
Scratcher
100+ posts
The Opposite of the Join Block
Full support. This would be very useful for certain projects.
- coincidenceithink
-
New Scratcher
9 posts
The Opposite of the Join Block
Also,here's a workaround though(delete letter () of []::operators)
define delete letter (ltr) of (word)support for the original because this would be helpful for decoding and other stuff and the workaround is a bit long especially for new scratchers
delete (all v) of [ltrs v]
repeat (length of (word))
add (letter (length of [ltrs v] ::list) of (word)) to [ltrs v]
end
delete (ltr) of [ltrs v]
set [result v] to []
repeat (length of [ltrs v] :: list)
set [result v] to (join (result) (item (length of (result) + (1) ::operators) of [ltrs v] :: list))
end
- fox_creations
-
Scratcher
63 posts
The Opposite of the Join Block
Support(delete [first v] [c] of [car] :: operators)
(delete [last v] [c] of [car] :: operators)
(delete [all v] [c] of [car] :: operators)
The output would be “ar” because it is deleting the c from car. What happens when something like this is put in you ask?(delete [all v] [yay] of [yayyayyayyaytyayyayyay] :: operators)
The output would be “t”
Okay here's more examples:(delete [first v] [yay] of [yayyayyayyaytyayyayyay] :: operators)
Output: yayyayyaytyayyayyay(delete [last v] [yay] of [yayyayyayyaytyayyayyay] :: operators)
Output: yayyayyayyaytyayyay(delete [all v] [h] of [hi there! ;D] :: operators)
Output: i tere! ;D
I hope you like my idea.If you found a duplicate, please tell me. I couldn't find one.
PLEASE NOTE THAT THE LIST IS NO LONGER BEING UPDATED. THANK YOU. VVVVV
Last edited by fox_creations (Oct. 1, 2021 15:49:44)
- man-o-valor
-
Scratcher
94 posts
The Opposite of the Join Block
SUPPORT! I have had a situation like this where i needed to delete a character from the end of a variable. I made a workaround but it made me think about why there is not a block like this. If you are curious what this project is, it's scratch.mit.edu/projects/724040656
- man-o-valor
-
Scratcher
94 posts
The Opposite of the Join Block
Anyways, according to the post above, yes, I do support this. Below is the entire quote from the topic I made
There is, however, a problem of if there are multiple examples of something.(Remove [an] from [banana] :: operators)To solve this, there could be another block that could look like this:(Remove [first v] example of [an] from [banana] :: operators) // The result would display as "bana"If # is put into (example of ___), it will remove the number depending on which example it should remove (unless there is a hashtag already in the phrase it must remove it from)
The block can detect “First,” “Second,” “Last,” or “All” instances of a letter, number, or phrase, examples below:set [Score v] to (Remove [last v] example of [0] from (Score) :: operators) :: variablesset [Time v] to (timer)This block would make it possible to have scripts that always round down. If anyone has any input, please tell me.
set [Time v] to (join (Remove [last v] example of [#] from (Time) :: operators) [0] :: operators // This script sets the time to the rounded down time the timer displays
Suprise! there is a block that rounds down. it's in the dropdown of the abv operations block and it's called floor. (rounding up is called ceiling.)
([floor v] of (0.9))
say [returns 0]
- medians
-
Scratcher
1000+ posts
The Opposite of the Join Block
when green flag clicked
set [page v] to [1]
- radians
-
Scratcher
54 posts
The Opposite of the Join Block
when green flag clicked
set [page v] to [1]
- Kitten-da-Cat
-
Scratcher
1000+ posts
The Opposite of the Join Block
Please do not bhlodk spamamamaMwhen green flag clicked
set [page v] to [1]
- Discussion Forums
- » Suggestions
-
» The Opposite of the Join Block















If you found a duplicate, please tell me. I couldn't find one. 


