Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escape special characters +-&|!(){}[]^"~*?:\ - e.g. \+ \* \!
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
How to optimize gas usage in a smart contract?

It's good when a smart contract needs as little gas as possible for a specific action. So a developer might want to optimize the code, making it use less gas. But how to do it? Of course, it depends on a specific case, so there is no universal answer. But maybe there are some well-known best practices that are good to begin with? Are there some posts on the topic of gas optimization in TON?


This question was imported from Telegram Chat: https://t.me/tondev/136089

  
  
Posted 11 months ago
Votes Newest

Answers


There is a page on ton.org that presents some best practices for optimizing gas:

https://docs.ton.org/develop/howto/fees-low-level

  
  
Posted 10 months ago
11K Views
1 Answer
11 months ago
10 months ago
Tags